Search code examples
asmxcode-coveragemstest

how to exclude a Web Reference from Code Coverage in VS 2008 Team System


When I run my MSTest tests in Visual Studio 2008 Team System and get code coverage results, I always see a particular web service included. I don't care how well this web service is tested, I'm intentionally only using a small part of it. How can I exclude the Web Reference from showing up in my Code Coverage results?

I see that someone asked this very question over on Microsoft Connect and it's marked as postponed, but I was hoping someone knew of a workaround.


Solution

  • A work-around would be to put the web service in a separate assembly and not run code coverage on that assembly/project.