nunit - Ignore Test or TestFixture based on condition -


We have got some integration tests in our solution. To run these tests, simulation software should be installed on the developer pc.

Although this software is not installed on every developer PC, if the simulation software is not installed then these tests should be omitted otherwise ==> NullRefException

I now have a "conditionally ignored" test for testers I am looking for the route.

If something (simulationFilesExist) performs testfixture then leave the second testfixture

NIITs give some useful things unseen and clearly, but it is not silent what I want

Thanks

Use some code in your test or stability set up method Which detects whether the simulation software is installed or not and if it is not. [Set-up] Public Zero teststetup () (If TestHelper.SimulationFilesExist ()) {Assert.Ignore ("do not install simulation files")

or

  [TestFixtureSetUp] Public Zero Stability Setup () (If TestHelper.SimulationFilesExist (!)) {Assert.Ignore ("Simulation files are not installed.}}"  

Comments

Popular posts from this blog

MySql variables and php -

url rewriting - How to implement the returnurl like SO in PHP? -

Which Python client library should I use for CouchdB? -