X-Git-Url: https://adrianiainlam.tk/git/?a=blobdiff_plain;f=test.sh;h=3194c72cbb40661e179fc494d596a25ba3c9dcfa;hb=f9b5a82c0e67c25b47cc5a40b46ca2f1056c35f5;hp=f54d6e0f0efa1054c83a8b995ba992572dc8757e;hpb=7ad6c698d28d7d0f0770e1f6490f1a9649c64b6f;p=dygraphs.git diff --git a/test.sh b/test.sh index f54d6e0..3194c72 100755 --- a/test.sh +++ b/test.sh @@ -16,4 +16,9 @@ if [ $? != 0 ]; then exit 1 fi -phantomjs phantom-driver.js +phantomjs phantom-driver.js $* | tee /tmp/test-results.txt +trap "rm -f /tmp/test-results.txt" EXIT +if grep -q 'FAIL' /tmp/test-results.txt; then + echo One or more tests failed. + exit 1 +fi