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

Ability to set StopOnError via .runsettings #675

Closed
queil opened this issue Nov 6, 2019 · 11 comments
Closed

Ability to set StopOnError via .runsettings #675

queil opened this issue Nov 6, 2019 · 11 comments
Assignees
Milestone

Comments

@queil
Copy link

queil commented Nov 6, 2019

It looks (both from documentation and code) that StopOnError is not supported. Are there any plans to support it?

@OsirisTerje
Copy link
Member

You're right it is not supported, and currently there are no plans. There haven't been much asking for supporting this either, so I think this is a first :-)

I can't see why I can't be supported, so let us see if this gets some more votes :-)

@OsirisTerje OsirisTerje added this to the 3.17 milestone Jan 29, 2020
OsirisTerje pushed a commit that referenced this issue Jan 29, 2020
@OsirisTerje OsirisTerje self-assigned this Jan 29, 2020
@OsirisTerje
Copy link
Member

@queil
3 up-votes are awesome, more than enough.

And, it is done!

Please check the dev build on https://www.myget.org/feed/nunit/package/nuget/NUnit3TestAdapter (One on or later than Jan 29th)

To enable it in runsettings:

<NUnit>
    <StopOnError>true</StopOnError>
</NUnit>

@queil
Copy link
Author

queil commented Jan 29, 2020

@OsirisTerje Thanks for that!

@queil
Copy link
Author

queil commented Feb 5, 2020

@OsirisTerje Hi, so we did some initial tests. Passing the param works fine. However, stopping on error itself only works for ParallelScope.None. Both ParallelScope.Children and ParallelScope.Fixtures seem to ignore the setting. Is that NUnit's or the VS Adapter's issue?

@OsirisTerje
Copy link
Member

Can you guys chime in on this one @rprouse @jnm2 @ChrisMaddock ? I would guess this is NUnit itself, since the adapter now only pass the parameter further down.
@queil Have you checked with nunit.console ? That is doing the same thing, so it should show the same behavior.

@queil
Copy link
Author

queil commented Feb 5, 2020

@OsirisTerje I haven't checked with nunit.console yet but I will try when I get a chance.

@ChrisMaddock
Copy link
Member

I’m not sure of the implementation of this one without checking, sorry. I suspect the problem will lie in the engine or framework, it’s not been a heavily used option up till now.

Interested to hear what you find, @queil

@queil
Copy link
Author

queil commented Feb 5, 2020

@ChrisMaddock @OsirisTerje So just tested it and nunit.console (https://github.com/nunit/nunit-console/releases/tag/v3.11) behaves the same way. I.e. stop on error is ignored when running tests in parallel. I guess it is by design?

@ChrisMaddock
Copy link
Member

Either 'by design' or 'by error'. 😄

I had a quick look, looks like the framework doesn't have any functionality to take into account tests that might be running in parallel. My opinion, is that that should be corrected - although I don't know the framework codebase well enough to know how it should be structured.

It would be pretty easy to do through the engine. Maybe we should move this feature up a level...

@OsirisTerje
Copy link
Member

@ChrisMaddock

  1. Yes, would be nice to have this in the next version
  2. Added this issue in NUnit Console/Engine : https://github.com/nunit/nunit-console/issues/734

@OsirisTerje
Copy link
Member

@queil Beta released on Nuget, see https://www.nuget.org/packages/NUnit3TestAdapter/3.17.0-beta.1 . Please check that it works :-)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants