General Feedback

More configuration

Started by rbirkby on 11,234 views

Hi,

I'd like to be able to stop processing tests from within the user interface. I can't find a way to do this.

Secondly, I'd like to exclude my Integration tests from NCrunch and just run my Unit tests. Currently, I do this via an NUnit [CategoryAttribute], so it would be great if NCrunch could provide a Category setting too.

Lastly, is it possible to exclude projects in the configuration? I have some projects in the solution with are rarely used.


Thanks,
Richard
I've seen that you can change which tests are run, by going to main menu > nCrunch > Tests, and then you can right-click tests to ignore them in nCrunch.

Edited

Hi Richard -

Thanks for the feedback!

Categorisation of tests via the NUnit Category attributes is on the list of future changes and shouldn't be far away.

As Simon mentioned, you can use the ignore features in the Test UI to selectively ignore integration tests that you find troublesome. Using this feature you can also ignore an entire project (and therefore all tests within it). If you are working as part of a team, you can also keep the ignored test configuration file under source control so your teammates can share it.

Of course, as a long term goal it's also worth trying to get integration tests running under NCrunch - This should always be possible, though depending on your tests, it may not be possible to do it overnight :)


Cheers,

Remco

Edited

Remco wrote:

Of course, as a long term goal it's also worth trying to get integration tests running under NCrunch - This should always be possible, though depending on your tests, it may not be possible to do it overnight :)



The Integration tests which we run on our CI build server take about 10 minutes. Do you see NCrunch being the right tool for running these sorts of tests?


Thanks for your help,
Richard
It can be - though there may be some setup required.

I'm currently using NCrunch on a project where we have numerous integration tests and a total running time of over an hour. The integration tests tend to trawl through in the background while the unit tests provide faster feedback.

The key is to ensure you use the parallel execution features, as otherwise the integration tests can block up the test pipeline.

NCrunch also sets an environment variable (%NCrunch%==1) in all of its worker processes, and you can use this as part of your build process (or test setup) to redirect your connections to a difference database/schema to run your tests against. This way you won't be interrupted by your integration tests using the same database as you may be manually using at the same time. I have plans to write an article on how to do this soon, as I feel its often a worthwhile step to take.

Post a reply

Log in to reply.