test: fix integration tests

- They should fail, if any test fails
- Use "set -e" instead of "|| exit 1", because it suffices to be specified
  at the top of each file
This commit is contained in:
Nils Knappmeier
2020-04-02 08:39:51 +02:00
committed by Hannah Wolfe
parent b454b02147
commit 645ac73844
3 changed files with 11 additions and 7 deletions
@@ -1,5 +1,7 @@
#!/bin/bash
set -e
cd "$( dirname "$( readlink -f "$0" )" )" || exit 1
# shellcheck disable=SC1090
[ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh"
@@ -20,8 +22,8 @@ for i in 0.10 0.12 4 5 6 7 8 9 10 11 ; do
mkdir target
nvm install "$i"
nvm exec "$i" npm install
nvm exec "$i" npm run test || exit 1
nvm exec "$i" npm run test-precompile || exit 1
nvm exec "$i" npm run test
nvm exec "$i" npm run test-precompile
echo Success
done