简体   繁体   English

具有代码覆盖范围的Visual Studio TFS构建

[英]Visual Studio TFS build with code coverage

Essentially what I would like to do is write a visual studio build script that will only build the solution if my code coverage requirements have been met. 本质上,我想做的是编写一个Visual Studio构建脚本,该脚本仅在满足我的代码覆盖要求的情况下构建解决方案。

So essentially, after compiling and running the automated testing of the solution, I want to pass the build (working with Team Foundation server) only if a certain % of the code is covered by testing. 因此,从本质上讲,在编译并运行解决方案的自动测试之后,仅当测试覆盖一定百分比的代码时,我才希望通过构建(与Team Foundation服务器一起使用)。

Any input is highly valued; 任何投入都受到高度重视; resources, a solution, or even "that's impossible" 资源,解决方案,甚至“不可能”

Thank you! 谢谢!

A bit late but for someone else looking at this post the following blog post explains how to do it 有点晚了,但是对于其他人正在看这篇文章,以下博客文章解释了如何做

Fail a Build if Code Coverage is Low 如果代码覆盖率低,则构建失败

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM