test: correct Travis tests suite to indicate failure by returning proper exit code

Signed-off-by: deadprogram <ron@hybridgroup.com>
This commit is contained in:
deadprogram 2017-02-23 11:51:16 +01:00
parent 4ab1c695a0
commit 65fd971c85
1 changed files with 4 additions and 0 deletions

View File

@ -8,6 +8,10 @@ go test -i ./...
for package in "${PACKAGES[@]}"
do
go test -coverprofile=tmp.cov gobot.io/x/$package
if [ $? -ne 0 ]
then
EXITCODE=1
fi
if [ -f tmp.cov ]; then
cat tmp.cov >> coverage.txt
rm tmp.cov