Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Consider failing tests a failure #50898

Merged
merged 1 commit into from
Apr 9, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 4 additions & 3 deletions eng/testing/RunnerTemplate.cmd
Original file line number Diff line number Diff line change
Expand Up @@ -59,10 +59,11 @@ echo ----- end %DATE% %TIME% ----- exit code %ERRORLEVEL% ----------------------
:: The helix work item should not exit with non-zero if tests ran and produced results
:: The special console runner for runtime returns 1 when tests fail
if %ERRORLEVEL%==1 (
exit /b 0
) else (
exit /b %ERRORLEVEL%
if not "%HELIX_WORKITEM_PAYLOAD%"=="" (
exit /b 0
)
)
exit /b %ERRORLEVEL%
:: ========================= END Test Execution =================================

:usage
Expand Down
9 changes: 6 additions & 3 deletions eng/testing/RunnerTemplate.sh
Original file line number Diff line number Diff line change
Expand Up @@ -225,8 +225,11 @@ popd >/dev/null
# The helix work item should not exit with non-zero if tests ran and produced results
# The special console runner for runtime returns 1 when tests fail
if [ "$test_exitcode" == "1" ]; then
exit 0
else
exit $test_exitcode
if [ -n "$HELIX_WORKITEM_PAYLOAD" ]; then
exit 0
fi
fi

exit $test_exitcode
fi