简体   繁体   English

访问Visual Studio Online中的代码覆盖率结果

[英]Access to code-coverage results in Visual Studio Online

My current project is hosted in Visual Studio Online. 我当前的项目托管在Visual Studio Online中。 With each build I can see what my code coverage is. 每次构建我都能看到我的代码覆盖范围。

However, I would like to write a build task that would fail the build or provide a warning if the code-coverage decreases when compared to the previous build. 但是,我想编写一个构建任务,如果代码覆盖率与之前的构建相比减少,则构建任务将无法构建或提供警告。

Does VSO offer this kind of information? VSO是否提供此类信息? Can anyone point me in the right direction or is what I'm asking currently not possible with VSO? 任何人都可以指出我正确的方向或者我现在要求VSO不可能吗?

Right now there is no built-in action, task or script which does this. 现在没有内置的动作,任务或脚本来执行此操作。 It should be possible to request the previous successful build from a custom task and compare the values though... 应该可以从自定义任务请求先前成功的构建并比较值但是...

Visualizing the trend can be achieved through the SonarQube integration. 通过SonarQube集成可以实现趋势的可视化。 Though it doesn't have a way yet to fail the build or issue a warning on a negative trend, it at least makes it very visible. 虽然它没有办法使构建失败或对负面趋势发出警告,但它至少使它非常明显。

When combined with Git, it may be a bit harder though, as a single build definition can cover multiple branches, and "the previously successful build" may be a completely different version of the software you're building. 当与Git结合使用时,它可能会有点困难,因为单个构建定义可以涵盖多个分支,并且“之前成功构建”可能是您正在构建的软件的完全不同版本。 Causing all kinds of false negatives. 导致各种假阴性。

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

相关问题 发布代码覆盖率在TFS 2015 / Visual Studio Team Services中无效(VS Online) - Publish code coverage does not work in TFS 2015 / Visual Studio Team Services (was VS Online) 代码覆盖率结果在本地Visual Studio和TFS构建服务器中不匹配 - Code coverage results do not match in local visual studio and TFS build server Visual Studio Online Build中的TypeScript - TypeScript in Visual Studio Online Build XamlObjectWriterException引发Visual Studio在线 - XamlObjectWriterException thrown on visual studio online TFS Build 2008构建Visual Studio 2010 Project的代码覆盖范围可能吗? - Code Coverage possible for TFS Build 2008 building Visual Studio 2010 Project? VS2010 RC团队构建代码涵盖范围是否要求将Visual Studio安装在构建服务器上? - Does VS2010 RC Team Build code coverage require Visual Studio to be installed on build server? 使用WebDriver和Visual Studio Online进行硒测试 - Selenium tests with WebDriver and Visual Studio Online 如何使用Visual Studio Online变量? - How to use Visual Studio Online variables? 打字稿无法在Visual Studio Online TFS上编译 - typescript not compiling on visual studio online tfs 使用javascript测试构建Visual Studio Online - Visual Studio Online build with javascript tests
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM