We are using Clover.NET
as our code coverage tool.
Obtaining
You can download the software from the Cenqua web site. Be sure to get the NAnt targets as well. If you are a member of the Spring.NET project, contact Mark to get the open source license for Clover.NET.
Usage
If you have installed Clover.NET into a folder other than the default C:\Program Files\Cenqua\Clover.NET, you can create a file called 'Spring.NET.xml' in your Home directory (e.g. C:\Documents and Settings\Administrator\Application Data\Spring.NET.xml) that will contain your unique settings for the installation location of Clover.NET. For example
You should then install the NAnt Clover tasks by putting the CloverNAnt.dll in the same installation directory as Clover.NET.
To instrument the code and run the tests:
To instrument the code, run the tests, and generate the code coverage report:
To clean the collected coverage data in the Clover.NET datafile:
You can also use the all in one convenience target: