简体   繁体   English

具有MSTests单元测试以及TFS2008和MsBuild的VS2010解决方案-无法运行单元测试

[英]VS2010 solution with MSTests unit tests and TFS2008 and MsBuild - fails to run unit test

I have a build setup on my TFS server (TFS2008) and it properly builds my VS2010 solution. 我在TFS服务器(TFS2008)上有一个构建设置,它可以正确构建我的VS2010解决方案。 (I did have to change the ToolsVersion to 4.0) (我确实必须将ToolsVersion更改为4.0)

My problem is when I try to include the build definition to run my MsTests based unit tests. 我的问题是当我尝试包括构建定义以运行基于MsTests的单元测试时。 The build fails with the following message in the BuildLog.txt files. 构建失败,并在BuildLog.txt文件中显示以下消息。

MSBUILD : warning : Visual Studio Team System for Software Testers or Visual Studio Team System for Software Developers is required to run tests as part of a Team Build. MSBUILD:警告:作为团队构建的一部分,需要运行Visual Studio Team System(用于软件测试人员)或Visual Studio Team System(用于软件开发人员)来运行测试。

I have installed Visual Studio 2010 Ultimate on this machine (the build server), but that hasnt changed anything and I am still getting the above error. 我已经在这台机器(构建服务器)上安装了Visual Studio 2010 Ultimate,但这还没有改变任何内容,但是我仍然遇到上述错误。

What is my build machine missing? 我的构建机缺少什么?

Configuration: TFS Server: TFS 2008 Build server: Separate machine (Has Vs2008 and VS2010 ultimate installed on it). 配置:TFS服务器:TFS 2008生成服务器:独立的机器(已安装Vs2008和VS2010 Ultimate)。 Solutions: VS2010 解决方案:VS2010

To get past this error what I needed to do was install both Visual Studio 2008 Developer edition and VS2010 Ultimate on the build machine. 要克服此错误,我需要做的是在构建计算机上安装Visual Studio 2008 Developer版本和VS2010 Ultimate。

(you may be able to get away with VS2010 Premium). (您也许可以摆脱VS2010 Premium)。

More info: http://blog.aggregatedintelligence.com/2011/03/vs2010-tfs-2008-and-unit-tests.html 更多信息: http//blog.aggregatedintelligence.com/2011/03/vs2010-tfs-2008-and-unit-tests.html

But now Mstest is failing with error code 1. 但是现在Mstest失败,错误代码为1。

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

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