Say I have Test assembly (NUnit compliant) App.Test.dll and a library to be tested App.dll.
How do I get the code coverage analysis using PartCover and NUint?
Say I have Test assembly (NUnit compliant) App.Test.dll and a library to be tested App.dll.
How do I get the code coverage analysis using PartCover and NUint?
The easiest way is to set up an NUnit test project (which runs App.Test.dll), then from PartCover call the NUnit console runner and pass the project name as a parameter. I have a blog post about it if you want to check that out.
(I haven't tried with .Net 4 or the latest versions of NUnit/PartCover but I'm assuming it's still the same).
I concur. In my experiments (see blog post here: http://www.csharpcity.com/using-partcover-and-nunit-for-code-coverage/) I set up a project with an NUnit-complaint "AutomatedTest" project (which referenced NUnit's framework DLL and outputted a DLL full of test classes), and ran that through PartCover.