Skip to content

Commit

Permalink
fix: enable test
Browse files Browse the repository at this point in the history
  • Loading branch information
just-mitch committed Mar 6, 2025
1 parent 7a49dc8 commit 7746725
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 13 deletions.
7 changes: 7 additions & 0 deletions spartan/bootstrap.sh
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,7 @@ function test_cmds {
echo "$hash timeout -v 30m ./spartan/bootstrap.sh test-kind-4epochs"
echo "$hash timeout -v 30m ./spartan/bootstrap.sh test-kind-upgrade-rollup-version"
echo "$hash timeout -v 30m ./spartan/bootstrap.sh test-prod-deployment"
echo "$hash timeout -v 30m ./spartan/bootstrap.sh test-cli-upgrade-with-lock"
fi
}

Expand Down Expand Up @@ -137,6 +138,12 @@ case "$cmd" in
"test-prod-deployment")
FRESH_INSTALL=false INSTALL_METRICS=false ./scripts/test_prod_deployment.sh
;;
"test-cli-upgrade-with-lock")
env
FRESH_INSTALL=false INSTALL_METRICS=false \
./scripts/test_kind.sh src/spartan/smoke.test.ts 1-validators.yaml upgrade-with-lock \
&& ./scripts/test_upgrade_rollup_with_lock.sh upgrade-with-lock
;;
"test-local")
# Isolate network stack in docker.
docker_isolate ../scripts/run_native_testnet.sh -i -val 3
Expand Down
Original file line number Diff line number Diff line change
@@ -1,22 +1,16 @@
#!/bin/bash

# This script is used to test the upgrade rollup with lock.
# The point of the test is primarily to ensure that the CLI is not broken, and the upgrade works.

set -eu

NAMESPACE=$1
ADDRESS=${2:-"0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266"} # first addr in junk mnemonic
L1_CHAIN_ID=${3:-1337}

image=$(kubectl get pod $NAMESPACE-aztec-network-boot-node-0 -n $NAMESPACE -o jsonpath="{.spec.containers[*].image}")

echo $image

# pull the image if it's not already pulled
if ! docker images $image --format "{{.Repository}}:{{.Tag}}" | grep -q $image; then
docker pull $image
fi

AZTEC_BIN="/usr/src/yarn-project/aztec/dest/bin/index.js"
EXE="docker run --rm --network=host $image $AZTEC_BIN"
AZTEC_BIN=$(git rev-parse --show-toplevel)/yarn-project/aztec/dest/bin/index.js
EXE="node --no-warnings $AZTEC_BIN"

# Create temporary files for port-forwarding output
boot_tmpfile=$(mktemp)
Expand Down Expand Up @@ -81,9 +75,8 @@ echo "Registry: $registry"
export L1_CHAIN_ID=$L1_CHAIN_ID
export ETHEREUM_HOSTS="http://localhost:$eth_port"
$(git rev-parse --show-toplevel)/spartan/scripts/upgrade_rollup_with_lock.sh \
--aztec-docker-image $image \
--aztec-bin $AZTEC_BIN \
--registry $registry \
--address $ADDRESS \
--deposit-amount 200000000000000000000000 \
--mint

0 comments on commit 7746725

Please sign in to comment.