diff options
author | Magnus Ahltorp <map@kth.se> | 2016-10-05 10:06:16 +0200 |
---|---|---|
committer | Magnus Ahltorp <map@kth.se> | 2016-10-05 10:08:43 +0200 |
commit | 1d902cd5813a2df252b6976bdcdc9cd7531590b4 (patch) | |
tree | cef355f80032c5e15893a5d96c52728d9b71b7d8 /test/scripts/light-system-test-start.sh | |
parent | 49b40a0170b80b204746ab3bc42a73c5c60bcf0c (diff) |
Move tests to shell scripts
Diffstat (limited to 'test/scripts/light-system-test-start.sh')
-rwxr-xr-x | test/scripts/light-system-test-start.sh | 33 |
1 files changed, 33 insertions, 0 deletions
diff --git a/test/scripts/light-system-test-start.sh b/test/scripts/light-system-test-start.sh new file mode 100755 index 0000000..38c50fc --- /dev/null +++ b/test/scripts/light-system-test-start.sh @@ -0,0 +1,33 @@ +#!/bin/sh + +set -o nounset +set -o errexit + +INSTDIR=../catlfish +PREFIX=.. + +. test.shvars + +for node in ${ERLANGNODES}; do + (cd ${INSTDIR}/tests ; ../bin/run_erl -daemon nodes/${node}/ nodes/${node}/log/ "exec ../bin/erl -config ${node}") +done +for i in 1 2 3 4 5 6 7 8 9 10; do + echo "waiting for system to start" + sleep 0.5 + allstarted=1 + notstarted= + for testurl in ${TESTURLS}; do + if curl -s --cacert ${INSTDIR}/tests/httpsca/demoCA/cacert.pem -4 https://${testurl} > /dev/null ; then + : + else + allstarted=0 + notstarted="${testurl} ${notstarted}" + fi + : + done + if [ ${allstarted} -eq 1 ]; then + break + elif [ ${i} -eq 10 ]; then + echo Not started: ${notstarted} + fi +done |