Having recently gotten into test driven development I am using the Nunit test runner shipped as part of resharper. It has some downsides in terms of there is no shortcut to run tests and I have to go looking for the Nunit test runner to invoke it using the mouse. It has a nice GUI and shows the results as part of the IDE well.
What do other people use for running unit tests against .net projects? I have googled other apps including MBUnit and the Unit test App from Nunit.org and wondered what comes out on top for people.
The nunit.exe program is a graphical runner. It shows the tests in an explorer-like browser window and provides a visual indication of the success or failure of the tests. It allows you to selectively run single tests or suites and reloads automatically as you modify and re-compile your code.
The main difference is the ability of MsTest to execute in parallel at the method level. Also, the tight integration of MsTest with Visual Studio provides advantages in both speed and robustness when compared to NUnit. As a result, I recommend MsTest.
Nunit provides three different runners, which may be used to load and run your tests. The console runner, nunit-console.exe, is used for batch execution. The gui runner, nunit.exe, provides interactive loading and running of tests.
I've always been a fan of TestDriven.NET, I much prefer it over using ReSharper.
Resharper does have some shortcomings...but it is possible to configure it to do what you want...
You can configure keyboard options in Visual Studio. Also, you can use the Unit Test Explorer in Resharper to find the tests you want and add them to the current session. I usually configure a shortcut (Alt+U) that runs all the tests in my current session...that way as I'm developing I can run all of the unit tests I need in seconds.
Also check out:
ReSharper run all unit tests in a project or solution at once
Are there shortcut keys for ReSharper's Unit Test Runner?
However, it would be nice if this didn't have to be manually configured! (Yes! I'm looking at you Resharper Dev team! LOL)
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With