Tuesday, September 15, 2009

Nunit for unit testing

Recently I installed .net 3.5 and visual studio 2008 on a new machine. Created one project and tried running the NUnit on the DLL but it gave me an exception called System.badImage... I tried with sample Arithmatic application available on web, but still the same error. When I saw the CLR version of NUnit using Help menu, it showed 1.1... I found the gui.exe.config file and amended the entries in there and added for 3.5... whew it started working
<startup>
<supportedRuntime version="v3.5.7121"/>
<supportedRuntime version="v3.5" />
<supportedRuntime version="v2.0.50727" />
<supportedRuntime version="v2.0.40301" />
<supportedRuntime version="v1.1.4322" />
<supportedRuntime version="v1.0.3705" />
<requiredRuntime version="v1.0.3705" />
</startup>

If you are new to NUnit then browse at samuel's blog, he has written excellent post to begin with nUnit.

Testing self app is always good.

No comments:

Post a Comment