문제

NCover has an attribute IgnoreFromCoverage that allows for code to be marked for exclusion during code coverage analysis. Is there a way to do this with the VSTS Code Coverage Tools?

Obvious uses for this would be auto property getters and setters, non obvious uses may be code generated by R# equals implementation or ORM generated code.

도움이 되었습니까?

해결책

For Visual Studio 2010 you can use the ExcludeFromCodeCoverage attribute. You can apply the attribute to an entire class or to methods within a class. See MSDN for more information.

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top