aboutsummaryrefslogtreecommitdiffstats
path: root/build/fullnode-test.sh
diff options
context:
space:
mode:
authorbojie <bojie@dexon.org>2019-01-18 19:30:23 +0800
committerWei-Ning Huang <w@byzantine-lab.io>2019-06-12 17:27:21 +0800
commitc2c6f9629f7ff386b9599cf3fce73de0a3c234a6 (patch)
treef6b38df6f819bcd60e1995652633d08e1357cfdf /build/fullnode-test.sh
parentc31e41053665d4a4cd5eb3d7bc5ae7dbe889499e (diff)
downloadgo-tangerine-c2c6f9629f7ff386b9599cf3fce73de0a3c234a6.tar
go-tangerine-c2c6f9629f7ff386b9599cf3fce73de0a3c234a6.tar.gz
go-tangerine-c2c6f9629f7ff386b9599cf3fce73de0a3c234a6.tar.bz2
go-tangerine-c2c6f9629f7ff386b9599cf3fce73de0a3c234a6.tar.lz
go-tangerine-c2c6f9629f7ff386b9599cf3fce73de0a3c234a6.tar.xz
go-tangerine-c2c6f9629f7ff386b9599cf3fce73de0a3c234a6.tar.zst
go-tangerine-c2c6f9629f7ff386b9599cf3fce73de0a3c234a6.zip
travis: add new CI test to test fullnode (#138)
Diffstat (limited to 'build/fullnode-test.sh')
-rwxr-xr-xbuild/fullnode-test.sh55
1 files changed, 55 insertions, 0 deletions
diff --git a/build/fullnode-test.sh b/build/fullnode-test.sh
new file mode 100755
index 000000000..589e707bf
--- /dev/null
+++ b/build/fullnode-test.sh
@@ -0,0 +1,55 @@
+#!/bin/bash
+
+sleep 20
+
+tarAndUpload()
+{
+ name=travis-fail-$(date +%s).tar.gz
+ tar -zcvf $name test
+ echo "Verify fail and upload $name"
+ PKG_CONFIG_PATH=/usr/local/opt/openssl/lib/pkgconfig go run build/testtool/testtool.go upload $name dexon-builds
+}
+
+endpoint=http://127.0.0.1:8545
+
+for round in 0 1 2
+do
+
+echo "Start verify round $round"
+ for index in 0 1 2 3
+ do
+ echo "Verify gov master public key round $round index $index"
+ cmd="PKG_CONFIG_PATH=/usr/local/opt/openssl/lib/pkgconfig go run build/testtool/testtool.go verifyGovMPK $endpoint $round $index"
+ eval $cmd
+ code=$?
+
+ if [ $code == 1 ]; then
+ tarAndUpload
+ exit 1
+ fi
+ done
+
+echo "Start verify CRS"
+cmd="PKG_CONFIG_PATH=/usr/local/opt/openssl/lib/pkgconfig go run build/testtool/testtool.go verifyGovCRS $endpoint $round"
+eval $cmd
+code=$?
+
+if [ $code == 1 ]; then
+ tarAndUpload
+ exit 1
+fi
+
+if [ $round -lt 2 ]; then
+ cmd="PKG_CONFIG_PATH=/usr/local/opt/openssl/lib/pkgconfig go run build/testtool/testtool.go monkeyTest $endpoint"
+ eval $cmd
+ code=$?
+
+ if [ $code == 1 ]; then
+ tarAndUpload
+ exit 1
+ fi
+
+ echo "Sleep 30 sec wait for next round"
+ sleep 30
+fi
+done \ No newline at end of file