Visual Studio测试任务在管道中失败,但在测试控制台中成功

时间:2019-01-30 18:56:19

标签: azure-devops vstest vstest.console.exe vstest.console

我正在使用Visual studio test task来运行所有测试,并将其作为构建定义的一部分。 我已启用的选项如下所示:

enter image description here

现在,这里的问题是,当我从build pipleine运行它们时,我的某些测试始终会失败,但是当我通过pipleine运行它们时,所有这些测试似乎都通过了 vstests console.exe命令。

ex: "C:\Program Files (x86)\Microsoft Visual Studio 14.0\Common7\IDE\CommonExtensions\Microsoft\TestWindow\VSTest.Console" <path to dll>

有人知道这里有什么问题吗? 谢谢。

1 个答案:

答案 0 :(得分:0)

使用Installed by tools installer选项,我需要查看您的工具安装任务在做什么以提供其他信息。也许您没有安装与测试兼容的版本?

enter image description here


如果您没有特定的要求调用其他测试平台版本,则可以尝试使用Latest

enter image description here

OR

由于您正在致电...\Microsoft Visual Studio 14.0\...\VSTest.Console,因此您可能需要选择Visual Studio 2015选项。

enter image description here

相关问题