Skip to content

Commit 6855a96

Browse files
committed
revert extra changes
1 parent df09c06 commit 6855a96

File tree

2 files changed

+68
-62
lines changed

2 files changed

+68
-62
lines changed

build/avalanche-network-runner

-62.3 MB
Binary file not shown.

scripts/tests.e2e.sh

+68-62
Original file line numberDiff line numberDiff line change
@@ -17,28 +17,28 @@ DEFAULT_VERSION_2=v1.10.9
1717
DEFAULT_SUBNET_EVM_VERSION=v0.5.5
1818

1919
if [ $# == 0 ]; then
20-
VERSION_1=$DEFAULT_VERSION_1
21-
VERSION_2=$DEFAULT_VERSION_2
22-
SUBNET_EVM_VERSION=$DEFAULT_SUBNET_EVM_VERSION
20+
VERSION_1=$DEFAULT_VERSION_1
21+
VERSION_2=$DEFAULT_VERSION_2
22+
SUBNET_EVM_VERSION=$DEFAULT_SUBNET_EVM_VERSION
2323
else
24-
VERSION_1=$1
25-
if [[ -z "${VERSION_1}" ]]; then
26-
echo "Missing version argument!"
27-
echo "Usage: ${0} [VERSION_1] [VERSION_2] [SUBNET_EVM_VERSION]" >>/dev/stderr
28-
exit 255
29-
fi
30-
VERSION_2=$2
31-
if [[ -z "${VERSION_2}" ]]; then
32-
echo "Missing version argument!"
33-
echo "Usage: ${0} [VERSION_1] [VERSION_2] [SUBNET_EVM_VERSION]" >>/dev/stderr
34-
exit 255
35-
fi
36-
SUBNET_EVM_VERSION=$3
37-
if [[ -z "${SUBNET_EVM_VERSION}" ]]; then
38-
echo "Missing version argument!"
39-
echo "Usage: ${0} [VERSION_1] [VERSION_2] [SUBNET_EVM_VERSION]" >>/dev/stderr
40-
exit 255
41-
fi
24+
VERSION_1=$1
25+
if [[ -z "${VERSION_1}" ]]; then
26+
echo "Missing version argument!"
27+
echo "Usage: ${0} [VERSION_1] [VERSION_2] [SUBNET_EVM_VERSION]" >> /dev/stderr
28+
exit 255
29+
fi
30+
VERSION_2=$2
31+
if [[ -z "${VERSION_2}" ]]; then
32+
echo "Missing version argument!"
33+
echo "Usage: ${0} [VERSION_1] [VERSION_2] [SUBNET_EVM_VERSION]" >> /dev/stderr
34+
exit 255
35+
fi
36+
SUBNET_EVM_VERSION=$3
37+
if [[ -z "${SUBNET_EVM_VERSION}" ]]; then
38+
echo "Missing version argument!"
39+
echo "Usage: ${0} [VERSION_1] [VERSION_2] [SUBNET_EVM_VERSION]" >> /dev/stderr
40+
exit 255
41+
fi
4242
fi
4343

4444
echo "Running e2e tests with:"
@@ -56,46 +56,51 @@ export CGO_CFLAGS="-O -D__BLST_PORTABLE__"
5656
############################
5757
AVALANCHEGO_REPO=/tmp/avalanchego-repo/
5858

59-
if [ ! -d $AVALANCHEGO_REPO ]; then
60-
git clone https://github.com/ava-labs/avalanchego/ $AVALANCHEGO_REPO
59+
if [ ! -d $AVALANCHEGO_REPO ]
60+
then
61+
git clone https://github.com/ava-labs/avalanchego/ $AVALANCHEGO_REPO
6162
fi
6263

6364
VERSION_1_DIR=/tmp/avalanchego-${VERSION_1}/
64-
if [ ! -f ${VERSION_1_DIR}/avalanchego ]; then
65-
echo building avalanchego $VERSION_1
66-
rm -rf ${VERSION_1_DIR}
67-
mkdir -p ${VERSION_1_DIR}
68-
cd $AVALANCHEGO_REPO
69-
git checkout $VERSION_1
70-
./scripts/build.sh
71-
cp -r build/* ${VERSION_1_DIR}
65+
if [ ! -f ${VERSION_1_DIR}/avalanchego ]
66+
then
67+
echo building avalanchego $VERSION_1
68+
rm -rf ${VERSION_1_DIR}
69+
mkdir -p ${VERSION_1_DIR}
70+
cd $AVALANCHEGO_REPO
71+
git checkout $VERSION_1
72+
./scripts/build.sh
73+
cp -r build/* ${VERSION_1_DIR}
7274
fi
7375

7476
VERSION_2_DIR=/tmp/avalanchego-${VERSION_2}/
75-
if [ ! -f ${VERSION_2_DIR}/avalanchego ]; then
76-
echo building avalanchego $VERSION_2
77-
rm -rf ${VERSION_2_DIR}
78-
mkdir -p ${VERSION_2_DIR}
79-
cd $AVALANCHEGO_REPO
80-
git checkout $VERSION_2
81-
./scripts/build.sh
82-
cp -r build/* ${VERSION_2_DIR}
77+
if [ ! -f ${VERSION_2_DIR}/avalanchego ]
78+
then
79+
echo building avalanchego $VERSION_2
80+
rm -rf ${VERSION_2_DIR}
81+
mkdir -p ${VERSION_2_DIR}
82+
cd $AVALANCHEGO_REPO
83+
git checkout $VERSION_2
84+
./scripts/build.sh
85+
cp -r build/* ${VERSION_2_DIR}
8386
fi
8487

8588
SUBNET_EVM_REPO=/tmp/subnet-evm-repo/
86-
if [ ! -d $SUBNET_EVM_REPO ]; then
87-
git clone https://github.com/ava-labs/subnet-evm/ $SUBNET_EVM_REPO
89+
if [ ! -d $SUBNET_EVM_REPO ]
90+
then
91+
git clone https://github.com/ava-labs/subnet-evm/ $SUBNET_EVM_REPO
8892
fi
8993

9094
SUBNET_EVM_VERSION_DIR=/tmp/subnet-evm-${SUBNET_EVM_VERSION}/
91-
if [ ! -f $VERSION_1_DIR/plugins/srEXiWaHuhNyGwPUi444Tu47ZEDwxTWrbQiuD7FmgSAQ6X7Dy ]; then
92-
echo building subnet-evm $SUBNET_EVM_VERSION
93-
rm -rf ${SUBNET_EVM_VERSION_DIR}
94-
mkdir -p ${SUBNET_EVM_VERSION_DIR}
95-
cd $SUBNET_EVM_REPO
96-
git checkout $SUBNET_EVM_VERSION
97-
# NOTE: We are copying the subnet-evm binary here to a plugin hardcoded as srEXiWaHuhNyGwPUi444Tu47ZEDwxTWrbQiuD7FmgSAQ6X7Dy which corresponds to the VM name `subnetevm` used as such in the test
98-
./scripts/build.sh $VERSION_1_DIR/plugins/srEXiWaHuhNyGwPUi444Tu47ZEDwxTWrbQiuD7FmgSAQ6X7Dy
95+
if [ ! -f $VERSION_1_DIR/plugins/srEXiWaHuhNyGwPUi444Tu47ZEDwxTWrbQiuD7FmgSAQ6X7Dy ]
96+
then
97+
echo building subnet-evm $SUBNET_EVM_VERSION
98+
rm -rf ${SUBNET_EVM_VERSION_DIR}
99+
mkdir -p ${SUBNET_EVM_VERSION_DIR}
100+
cd $SUBNET_EVM_REPO
101+
git checkout $SUBNET_EVM_VERSION
102+
# NOTE: We are copying the subnet-evm binary here to a plugin hardcoded as srEXiWaHuhNyGwPUi444Tu47ZEDwxTWrbQiuD7FmgSAQ6X7Dy which corresponds to the VM name `subnetevm` used as such in the test
103+
./scripts/build.sh $VERSION_1_DIR/plugins/srEXiWaHuhNyGwPUi444Tu47ZEDwxTWrbQiuD7FmgSAQ6X7Dy
99104
fi
100105

101106
############################
@@ -118,26 +123,27 @@ killall avalanche-network-runner || true
118123

119124
echo "launch local test cluster in the background"
120125
bin/avalanche-network-runner \
121-
server \
122-
--log-level debug \
123-
--port=":8080" \
124-
--snapshots-dir=$snapshots_dir \
125-
--grpc-gateway-port=":8081" &
126+
server \
127+
--log-level debug \
128+
--port=":8080" \
129+
--snapshots-dir=$snapshots_dir \
130+
--grpc-gateway-port=":8081" &
126131
#--disable-nodes-output \
127132
PID=${!}
128133

129-
function cleanup() {
134+
function cleanup()
135+
{
130136
echo "shutting down network runner"
131137
kill ${PID}
132138
}
133139
trap cleanup EXIT
134140

135141
echo "running e2e tests"
136142
./tests/e2e/e2e.test \
137-
--ginkgo.v \
138-
--ginkgo.fail-fast \
139-
--log-level debug \
140-
--grpc-endpoint="0.0.0.0:8080" \
141-
--grpc-gateway-endpoint="0.0.0.0:8081" \
142-
--avalanchego-path-1=${VERSION_1_DIR}/avalanchego \
143-
--avalanchego-path-2=${VERSION_2_DIR}/avalanchego
143+
--ginkgo.v \
144+
--ginkgo.fail-fast \
145+
--log-level debug \
146+
--grpc-endpoint="0.0.0.0:8080" \
147+
--grpc-gateway-endpoint="0.0.0.0:8081" \
148+
--avalanchego-path-1=${VERSION_1_DIR}/avalanchego \
149+
--avalanchego-path-2=${VERSION_2_DIR}/avalanchego

0 commit comments

Comments
 (0)