@@ -17,28 +17,28 @@ DEFAULT_VERSION_2=v1.10.9
17
17
DEFAULT_SUBNET_EVM_VERSION=v0.5.5
18
18
19
19
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
23
23
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
42
42
fi
43
43
44
44
echo " Running e2e tests with:"
@@ -56,46 +56,51 @@ export CGO_CFLAGS="-O -D__BLST_PORTABLE__"
56
56
# ###########################
57
57
AVALANCHEGO_REPO=/tmp/avalanchego-repo/
58
58
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
61
62
fi
62
63
63
64
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}
72
74
fi
73
75
74
76
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}
83
86
fi
84
87
85
88
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
88
92
fi
89
93
90
94
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
99
104
fi
100
105
101
106
# ###########################
@@ -118,26 +123,27 @@ killall avalanche-network-runner || true
118
123
119
124
echo " launch local test cluster in the background"
120
125
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" &
126
131
# --disable-nodes-output \
127
132
PID=${! }
128
133
129
- function cleanup() {
134
+ function cleanup()
135
+ {
130
136
echo " shutting down network runner"
131
137
kill ${PID}
132
138
}
133
139
trap cleanup EXIT
134
140
135
141
echo " running e2e tests"
136
142
./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