在Jenkins中运行MsTest失败,CreateProcess错误= 5,拒绝访问

时间:2017-05-19 13:15:39

标签: jenkins mstest

我正在运行MsTest作为Jenkins的构建步骤,但它失败了:

[Test] $ "c:\Program Files (x86)\Microsoft Visual Studio 14.0\Common7\IDE" /resultsfile:TestResult.trx /noisolation "/testcontainer:C:\Program Files (x86)\Jenkins\workspace\Test\UnitTestProject1\bin\Debug\UnitTestProject1.dll"
Access is denied
FATAL: MSTest command execution failed
java.io.IOException: Cannot run program "c:\Program Files (x86)\Microsoft Visual Studio 14.0\Common7\IDE" (in directory "C:\Program Files (x86)\Jenkins\workspace\Test"): CreateProcess error=5, Access is denied

我使用MsTest插件。知道我在这里做错了吗?

1 个答案:

答案 0 :(得分:4)

您需要在MSTest设置中指定包含MSTest可执行文件的完整路径,目前它正在尝试将“IDE”作为可执行文件运行!