Continue on error/exception
See original GitHub issueUse case(s)
It is desirable to run all test projects as individual targets and not stop on the first time NonZeroExitCodeException, skipping the remaining test projects.
Description
Using simple-exec to run dotnet test {project} will return a NonZeroException if any test fails.
However I have multiple test projects each run as individual targets. I want to record that they failed but I don’t (necessarily) want bullseye to stop. I would like the fact that the target has failed to be recorded, processing to continue and then build “fails” at the end.
Alternatives
Capture the NonZeroExitCodeException and flip a staic flag oneOrMoreTestsFailed:

Problem 1 with this: the individual targets say “succeeded” when it is desirable they should say failed!:

Problem 2: doesn’t work when running specific target test

Issue Analytics
- State:
- Created 4 years ago
- Comments:14 (14 by maintainers)

Top Related StackOverflow Question
Close. I’ll come back to it when the itch needs scratching.
We’ll chat about this next week xx