Skip to content

Commit

Permalink
fix(run_unit_tests)_: don't exit in nightly runs (#5808)
Browse files Browse the repository at this point in the history
  • Loading branch information
igor-sirotin authored Sep 9, 2024
1 parent 17c30ac commit 00db9c8
Showing 1 changed file with 11 additions and 7 deletions.
18 changes: 11 additions & 7 deletions _assets/scripts/run_unit_tests.sh
Original file line number Diff line number Diff line change
Expand Up @@ -127,13 +127,17 @@ else
wait
fi

for exit_code_file in "${GIT_ROOT}"/exit_code_*.txt; do
read exit_code < "${exit_code_file}"
if [[ "${exit_code}" -ne 0 ]]; then
echo -e "${RED}Testing failed${RST}, exit code: ${exit_code}"
exit ${exit_code}
fi
done
# When running in PRs (count=1), early exit if any test failed.
# When running nightly (count>1), generate test stats ant coverage reports anyway.
if [[ $UNIT_TEST_COUNT -eq 1 ]]; then
for exit_code_file in "${GIT_ROOT}"/exit_code_*.txt; do
read exit_code < "${exit_code_file}"
if [[ "${exit_code}" -ne 0 ]]; then
echo -e "${RED}Testing failed${RST}, exit code: ${exit_code}"
exit ${exit_code}
fi
done
fi

# Gather test coverage results
merged_coverage_report="coverage_merged.out"
Expand Down

0 comments on commit 00db9c8

Please sign in to comment.