Skip to content

Commit

Permalink
fix: replace goerli with holesky in fork tests
Browse files Browse the repository at this point in the history
  • Loading branch information
bowenli86 committed Sep 18, 2024
1 parent 5946187 commit 27389c6
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 11 deletions.
3 changes: 1 addition & 2 deletions .env.example
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
RPC_MAINNET="https://eth.llamarpc.com"
# RPC_MAINNET="https://mainnet.infura.io/v3/API-KEY"
RPC_GOERLI="https://ethereum-goerli.publicnode.com"
RPC_HOLESKY=""
RPC_HOLESKY="https://ethereum-holesky-rpc.publicnode.com"
ETHERSCAN_API_KEY="API-KEY"
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ We have a few fork tests against ETH mainnet. Passing these requires the environ

Additionally, to run all tests in a forked environment, [install yq](https://mikefarah.gitbook.io/yq/v/v3.x/). Then, set up your environment using this script to read from `config.yml`:

`source source-env.sh [goerli|local]`
`source source-env.sh [holesky|local]`

Then run the tests:

Expand Down
4 changes: 2 additions & 2 deletions config.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
goerli:
CHAIN_ID: 5
holesky:
CHAIN_ID: 17000
EXECUTOR_MULTISIG: "0x3d9C2c2B40d890ad53E27947402e977155CD2808"
FOUNDRY_FUZZ_RUNS: 1
local:
Expand Down
12 changes: 6 additions & 6 deletions source-env.sh
Original file line number Diff line number Diff line change
Expand Up @@ -9,25 +9,25 @@ fi

# Check for arguments
if [ "$#" -ne 1 ]; then
echo "Usage: $0 [goerli|local]"
echo "Usage: $0 [holesky|local]"
return 1
fi

# Read the YAML file
CONFIG_FILE="config.yml"

case $1 in
goerli)
CHAIN_ID=$(yq e '.goerli.CHAIN_ID' $CONFIG_FILE)
EXECUTOR_MULTISIG=$(yq e '.goerli.EXECUTOR_MULTISIG' $CONFIG_FILE)
FOUNDRY_FUZZ_RUNS=$(yq e '.goerli.FOUNDRY_FUZZ_RUNS' $CONFIG_FILE)
holesky)
CHAIN_ID=$(yq e '.holesky.CHAIN_ID' $CONFIG_FILE)
EXECUTOR_MULTISIG=$(yq e '.holesky.EXECUTOR_MULTISIG' $CONFIG_FILE)
FOUNDRY_FUZZ_RUNS=$(yq e '.holesky.FOUNDRY_FUZZ_RUNS' $CONFIG_FILE)
;;
local)
CHAIN_ID=$(yq e '.local.CHAIN_ID' $CONFIG_FILE)
FOUNDRY_FUZZ_RUNS=$(yq e '.local.FOUNDRY_FUZZ_RUNS' $CONFIG_FILE)
;;
*)
echo "Invalid argument. Usage: $0 [goerli|local]"
echo "Invalid argument. Usage: $0 [holesky|local]"
return 1
;;
esac
Expand Down

0 comments on commit 27389c6

Please sign in to comment.