在TFS上构建要复制Node.js测试项目中的可执行文件 [英] Build on TFS wants to copy a executable from Node.js test project

查看:59
本文介绍了在TFS上构建要复制Node.js测试项目中的可执行文件的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我使用Node.js工具为量角器测试环境创建了一个Node.js项目,以在团队基础服务器上测试Web应用程序。在本地,我可以创建测试项目并使用调试器运行它。但是,在TFS上的构建不起作用。

I created a Node.js project for an protractor test environment using the Node.js Tools to test a web application on a team foundation server. Locally i can create the test project and run it with the debugger. However, the build on the TFS does not work.

日志:

"<PATH>\TestProject.Web.Protractor.Tests.njsproj" (13) on node 2 (default targets).
13>PrepareForBuild:
     Creating directory "obj\Debug\".
   CoreCompile:
     Creating directory "bin".
     Copying file from "C:\Program Files (x86)\MSBuild\Microsoft\VisualStudio\v14.0\Node.js Tools\Microsoft.NodejsTools.WebRole.dll" to "bin\Microsoft.NodejsTools.WebRole.dll".
   _CopyWebApplicationLegacy:
     Copying Web Application Project Files for TestProject.Web.Protractor.Tests
     Creating directory "<PATH>\bin\_PublishedWebsites\TestProject.Web.Protractor.Tests\bin".
13>C:\Program Files (x86)\MSBuild\Microsoft\VisualStudio\v14.0\WebApplications\Microsoft.WebApplication.targets(136,5): error MSB3030: Could not copy the file "obj\Debug\TestProject.Web.Protractor.Tests.exe" because it was not found. 


推荐答案

分析Microsoft.WebApplication.targets后,我发现切换 Disable_CopyWebApplication 禁用复制过程。

After analyzing the Microsoft.WebApplication.targets i found the switch Disable_CopyWebApplication to disable the copy process.

在我的项目文件中TestProject.Web.Protractor.Tests。 njsproj将< Disable_CopyWebApplication> True< / Disable_CopyWebApplication> 添加到属性组,它将可以正常工作:)

Inside the project file for me TestProject.Web.Protractor.Tests.njsproj add <Disable_CopyWebApplication>True</Disable_CopyWebApplication> to the property group and it will work fine :)

<Project DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003" ToolsVersion="4.0">
  <PropertyGroup>
    ...
    <Disable_CopyWebApplication>True</Disable_CopyWebApplication>
</PropertyGroup>
...

这篇关于在TFS上构建要复制Node.js测试项目中的可执行文件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆