-
Notifications
You must be signed in to change notification settings - Fork 41
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
fe19560
commit 815c4fb
Showing
2 changed files
with
53 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
ethereum_package: | ||
participants: | ||
- el_type: reth | ||
cl_type: lighthouse | ||
optimism_package: | ||
op_contract_deployer_params: | ||
image: us-docker.pkg.dev/oplabs-tools-artifacts/images/op-deployer:v0.0.11 | ||
chains: | ||
- network_params: | ||
isthmus_time_offset: 0 | ||
participants: | ||
- el_type: op-geth | ||
el_image: us-docker.pkg.dev/oplabs-tools-artifacts/images/op-geth:latest | ||
cl_type: op-node | ||
cl_image: us-docker.pkg.dev/oplabs-tools-artifacts/images/op-node:develop | ||
cl_extra_params: | ||
- "--l1.trustrpc=true" | ||
batcher_params: | ||
extra_params: | ||
- "--throttle-interval=0" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
setup() { | ||
load "../lib/bats-support/load.bash" | ||
load "../lib/bats-assert/load.bash" | ||
} | ||
|
||
teardown() { | ||
|
||
} | ||
|
||
@test "should have isthmus time if isthmus_time_offset is configured" { | ||
local ENCLAVE_ID=op-isthmus--001 | ||
|
||
# First we start the enclave | ||
run kurtosis run --enclave $ENCLAVE_ID . --args-file test/e2e/tests/assets/kurtosis_args_isthmus.yaml | ||
assert_success | ||
|
||
# We get the UUID of the op-geth service | ||
local OP_GETH_SERVICE_UUID=$(kurtosis enclave inspect $ENCLAVE_ID --full-uuids| grep op-el-1-op-geth-op-node-op-kurtosis | awk '{print $1;}') | ||
assert [ -n "$OP_GETH_SERVICE_UUID" ] | ||
|
||
# Now we find its RPC URL | ||
local OP_GETH_RPC_URL=$(kurtosis service inspect $ENCLAVE_ID $OP_GETH_SERVICE_UUID | grep ' rpc:' | awk '{print $4;}') | ||
assert [ -n "$OP_GETH_RPC_URL" ] | ||
|
||
# We ask the RPC for the node info | ||
local OP_GETH_NODE_INFO_JSON=$(curl -s -X POST -H "Content-Type: application/json" -d '{"jsonrpc":"2.0","method":"admin_nodeInfo","params":[],"id":1}' $OP_GETH_RPC_URL) | ||
|
||
# And finally we find the isthmusTime and make sure it's defined | ||
local OP_GETH_ISTHMUS_TIME=$(jq '.result.protocols.eth.config.isthmusTime' <<< $OP_GETH_NODE_INFO_JSON) | ||
assert_equal "$OP_GETH_ISTHMUS_TIME" "0" | ||
|
||
kurtosis enclave rm -f $ENCLAVE_ID | ||
} |