diff --git a/bin/run_ci_tests.sh b/bin/run_ci_tests.sh index 01d291b..faf04d6 100755 --- a/bin/run_ci_tests.sh +++ b/bin/run_ci_tests.sh @@ -32,13 +32,14 @@ run_tests() { } check_test_results() { - grep -e '^FAILED' "$TEST_LOG" >/dev/null - ret=$? - if [[ $ret == 0 ]]; then + failed_tests=$(grep -e '^FAILED' "$TEST_LOG" >/dev/null) + ret=0 + + if [[ ! -z "$failed_tests" ]]; then echo "------------------" echo "Some tests failed!" echo "------------------" - cat "$LOGFILE" + ret=2 else echo "All tests passed" fi @@ -56,8 +57,8 @@ install_repo run_tests check_test_results -tests_passed=$? +ret=$? cleanup -exit $tests_passed +exit $ret