Explorar o código

fix(target_chains/ethereum): update some configs to make js tests work (#1399)

Ali Behjati hai 1 ano
pai
achega
f18f1c8e7c

+ 1 - 1
package-lock.json

@@ -58316,7 +58316,7 @@
     },
     "target_chains/ethereum/contracts": {
       "name": "@pythnetwork/pyth-evm-contract",
-      "version": "1.4.0",
+      "version": "1.4.3",
       "license": "Apache-2.0",
       "dependencies": {
         "@certusone/wormhole-sdk": "^0.9.22",

+ 0 - 6
target_chains/ethereum/contracts/.env.test

@@ -1,12 +1,6 @@
 # Migrations Metadata
 MIGRATIONS_DIR=./migrations/test
 
-# By default tests are run against the tilt Wormhole deployment. If you wish to test against
-# the read-only Wormhole receiver instead, uncomment the following line:
-# MIGRATIONS_DIR=./migrations/prod-receiver
-
-MIGRATIONS_NETWORK=development
-
 # Wormhole Core Migrations
 INIT_SIGNERS=["0xbeFA429d57cD18b7F8A4d91A2da9AB4AF05d0FBe"]
 INIT_CHAIN_ID=0x2

+ 1 - 1
target_chains/ethereum/contracts/README.md

@@ -47,7 +47,7 @@ npx ganache-cli -e 10000 --deterministic --time="1970-01-02T00:00:00+00:00" --ho
 2. deploy the contracts:
 
 ```bash
-cp .env.test .env && npx truffle compile --all && npx truffle migrate
+cp .env.test .env && npx truffle compile --all && npx truffle migrate --network development
 ```
 
 3. Run the test suite:

+ 1 - 2
target_chains/ethereum/contracts/migrations/test/2_deploy_wormhole.js

@@ -1,5 +1,4 @@
-const loadEnv = require("../../scripts/loadEnv");
-loadEnv("../../");
+require("dotenv").config();
 
 const Setup = artifacts.require("Setup");
 const Implementation = artifacts.require("Implementation");

+ 1 - 2
target_chains/ethereum/contracts/migrations/test/3_deploy_pyth.js

@@ -1,5 +1,4 @@
-const loadEnv = require("../../scripts/loadEnv");
-loadEnv("../../");
+require("dotenv").config();
 
 const bs58 = require("bs58");
 

+ 1 - 1
target_chains/ethereum/contracts/package.json

@@ -1,6 +1,6 @@
 {
   "name": "@pythnetwork/pyth-evm-contract",
-  "version": "1.4.0",
+  "version": "1.4.3",
   "description": "",
   "private": "true",
   "devDependencies": {