2016-07-23 12:48:30 -04:00
|
|
|
#! /bin/bash
|
|
|
|
|
2016-07-23 19:38:44 -04:00
|
|
|
# integrations test
|
|
|
|
# this is the script run by eg CircleCI.
|
|
|
|
# It creates a docker container,
|
|
|
|
# installs the dependencies,
|
|
|
|
# and runs the tests.
|
|
|
|
# If we pushed to STAGING or MASTER,
|
|
|
|
# it will also run the tests for all dependencies
|
|
|
|
|
2016-07-24 14:08:47 -04:00
|
|
|
echo ""
|
|
|
|
echo "* building docker file"
|
2016-07-23 19:38:44 -04:00
|
|
|
docker build -t tester -f ./test/Dockerfile .
|
2016-07-24 14:08:47 -04:00
|
|
|
|
|
|
|
echo ""
|
|
|
|
echo "* running go tests and broadcast tests"
|
2016-07-23 19:38:44 -04:00
|
|
|
docker run -t tester bash test/run_test.sh
|
2016-07-24 14:08:47 -04:00
|
|
|
|
|
|
|
# test basic network connectivity
|
|
|
|
# by starting a local testnet and checking peers connect and make blocks
|
|
|
|
echo ""
|
|
|
|
echo "* running basic peer tests"
|
|
|
|
bash test/p2p/test.sh tester
|