-
Notifications
You must be signed in to change notification settings - Fork 700
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
Unit tests ignore xunit.runner.json
- Explains why the new stopOnFail
setting wasn't working
#2769
Comments
There is situations which is preferable the unit tests stooped instead of some never end. |
Sorry @BDisp but I can't parse what you're saying? Can you try again? |
I was referring that some unit tests fail silent and only opening the Tests on the drop down of the Output window we can verify there is an exception. But never mind. |
I think for local dev it would be nice to see all the failing tests rather than break on first (if that's what stopOnFail does). If you want it it in CI/CD though you could declare it as false in the json and add a CI build step that replaces false with true:
|
Cool. That's how we'll address this then. |
I've also fixed this in #2612 so it will be picked up for v2 when I merge that. |
See xunit/visualstudio.xunit#189
Fix is to set
xunit.runner.json
to Copy On Newer:(Adding this to
UnitTests.csproj
:We can remove this line from
./UnitTests/AssemblyInfo.cs
(it WAS what was preventing tests from running in parallel, but is no longer needed ifxunit.runner.json
is working):Once this is done, stopOnFail can be enabled by adding
"stopOnFail": true
toxunit.runner.json
.I'd like to know if anyone has an objection to setting
stopOnFail
to true. I'd DEF want this for CI/CD, but am not sure if I like it for dev work.The text was updated successfully, but these errors were encountered: