Excluding method from code coverage Ncover

1k views Asked by At

I have some dll's for which i want to run code coverage using TestDriven.net (ncover) with vs2010. There are some methods which i don't want to be included in the coverage result since those methods are already written by some other programmer the option of using CoverageExclusion attribute is not feasible. Is there any other way out ?

2

There are 2 answers

0
NCover Support On BEST ANSWER

Unfortunately, as far as I can tell, Testdriven.NET does not yet support using other NCover arguments, like //ea.

I found this post, where it was last discussed and Jamie Cansdale at Testdriven confirmed this:

https://groups.google.com/group/testdrivenusers/browse_thread/thread/a0dc80c40c5f8815?pli=1

I found an interesting post about using NCover 3.4.x with Testdriven, just FYI:

http://thepursuitofalife.com/how-to-connect-ncover-3-x-with-testdriven-net/

So, my best advice is to contact [email protected] to find out the latest on configuring and using NCover parameters.

Best Regards,

NCover Support

0
shamp00 On

NCover has a command line parameter //ea which stands for 'exclude attributes'. It allows you to provide a list of attributes marking classes or methods to exclude from coverage.

There is a blog post about it here.

This feature works with the version of NCover that comes with TestDriven.NET (1.5.8).