I'm trying to set Ant on my Win 8.1 and, of course, I've followed some hints already posted.
When I try to run Ant that's what I get:
C:\Users\Marco>ant
ANT_HOME is set incorrectly or ant could not be located. Please set ANT_HOME.
Checking my path:
C:\Users\Marco>echo %ANT_HOME%
C:\Program Files\apache-ant-1.9.3
C:\Users\Marco>echo %JAVA_HOME%
C:\Program Files\Java\jdk1.7.0_51
Again in my PATH:
C:\Users\Marco>echo %PATH%
C:\Users\Marco\AppData\Roaming\npm;C:\Program Files\nodejs\;C:\Program Files\apa
che-ant-1.9.3\bin;C:\Program Files\Java\jdk1.7.0_51\bin;C:\Program Files\apache-
ant-1.9.3\lib;D:\AndroidSDK\adt-bundle-windows-x86_64-20131030\sdk\tools;D:\Andr
oidSDK\adt-bundle-windows-x86_64-20131030\sdk\platform-tools;C:\Program Files (x
86)\NVIDIA Corporation\PhysX\Common;C:\Program Files (x86)\Intel\iCLS Client\;C:
\Program Files\Intel\iCLS Client\;C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\Syst
em32\Wbem;C:\WINDOWS\System32\WindowsPowerShell\v1.0\;C:\Program Files (x86)\Win
dows Live\Shared;C:\Program Files\Intel\Intel(R) Management Engine Components\DA
L;C:\Program Files\Intel\Intel(R) Management Engine Components\IPT;C:\Program Fi
les (x86)\Intel\Intel(R) Management Engine Components\DAL;C:\Program Files (x86)
\Intel\Intel(R) Management Engine Components\IPT;C:\Program Files (x86)\Intel\Op
enCL SDK\2.0\bin\x86;C:\Program Files (x86)\Intel\OpenCL SDK\2.0\bin\x64;C:\Prog
ram Files\nodejs\;C:\Users\Marco\node_modules\cordova\bin;D:\AndroidSDK\adt-bund
le-windows-x86_64-20131030\sdk\platform-tools;C:\Program Files (x86)\Git\cmd;C:\
Users\Marco\AppData\Roaming\npm
I've tried everything reading other posts but seems that nothing is right to launch ANT; what I'm missing?
Related
I use Delphi XE4 on Windows7 and use Microsoft.NET/Framework/V3.5/MSBuild.exe .
I have added the MSBuild path to the environment variable.
But got this error :(
$MSBuild.exe Project3.dproj /target:Build /property:configutation=Debug
Microsoft (R) Build Engine Version 3.5.30729.5420
[Microsoft .NET Framework, Version 2.0.50727.8762]
Copyright (C) Microsoft Corporation 2007. All rights reserved.
Build started 2017/10/30 ▒W▒▒ 10:45:40.
Project "C:\DXE4_LangDLL\Project3.dproj" on node 0 (Build target(s)).
C:\DXE4_LangDLL\Project3.dproj : error MSB4057: The target "Build" does not exist in the project.
Done Building Project "C:\DXE4_LangDLL\Project3.dproj" (Build target(s)) -- FAILED.
Build FAILED.
"C:\DXE4_LangDLL\Project3.dproj" (Build target) (1) ->
C:\DXE4_LangDLL\Project3.dproj : error MSB4057: The target "Build" does not exist in the project.
0 Warning(s)
1 Error(s)
Time Elapsed 00:00:00.00
I tried use Microsoft.NET/Framework/V2.0.50727/MSBuild.exe and got the same message.
I was confuse because used Delphi IDE to build project successfully.
Can someone help me?
You have to set first the environmental variables. There is a batch file, at the path
C:\Program Files (x86)\Embarcadero\Studio\XX\rsvars.bat
that i use for command-line batch files, where XX the version of your RAD Studio.
I am not sure if it will work for Git bash as it is, but you can create a batch file that will combine the lines of rsvars.bat and the MSBuild line, and execute it
Something like:
#SET BDS=C:\Program Files (x86)\Embarcadero\Studio\XX
#SET BDSINCLUDE=C:\Program Files (x86)\Embarcadero\Studio\XX\include
#SET BDSCOMMONDIR=C:\Users\Public\Documents\Embarcadero\Studio\XX
#SET FrameworkDir=C:\Windows\Microsoft.NET\Framework\v3.5
#SET FrameworkVersion=v3.5
#SET FrameworkSDKDir=
#SET PATH=%FrameworkDir%;%FrameworkSDKDir%;C:\Program Files (x86)\Embarcadero\Studio\XX\bin;C:\Program Files (x86)\Embarcadero\Studio\XX\bin64;C:\Users\Public\Documents\Embarcadero\InterBase\redist\InterBaseXE3\IDE_spoof;%PATH%
#SET LANGDIR=EN
#SET PLATFORM=
#SET PlatformSDK=
$MSBuild.exe Project3.dproj /target:Build /property:configutation=Debug
I have been setting up build configurations in TFS 2017.
As part of the build configuration I have Test steps.
When the build runs the test steps seems to run without error.
I committed some code in with a test I set to fail, to make sure that TFS stopped the build in the event tests fail. I queued a new build and then surprisingly the build completed with no issue.
I am having this issue on full framework libraries, that are being packaged into NuGet packages and also having it with .net core projects.
On evaluating the log for the test step I see the following messages.
These are from a .Net Core build
The build log
The build step for a core project
These ones are from a full framework build config
The build log for full framework
##[section]Starting: Test Assemblies **\*test*.dll;-:**\obj\**
==============================================================================
Task : Visual Studio Test
Description : Run tests with Visual Studio test runner
Version : 1.0.85
Author : Microsoft Corporation
Help : [More Information](https://go.microsoft.com/fwlink/?LinkId=624539)
==============================================================================
Preparing task execution handler.
Executing the powershell script: c:\agent\_work\_tasks\VSTest_ef087383-ee5e-42c7-9a53-ab56c98420f9\1.0.85\VSTest.ps1
Testing container: 'REGISTRY::HKEY_CLASSES_ROOT\CLSID\{177F0C4A-1CD3-4DE7-A32C-71DBBB9FA36D}'
Exists.
Adding Visual Studio setup helpers.
Getting Visual Studio setup instances.
Found 2 instances.
Description : Supports running automated tests and load tests remotely
DisplayName : Visual Studio Test Agent 2017
Id : 0f053fb9
InstallDate : System.Runtime.InteropServices.ComTypes.FILETIME
Name : VisualStudio/15.2.0+26430.6
Path : C:\Program Files (x86)\Microsoft Visual Studio\2017\TestAgent
Version : 15.0.26430.6
VersionString : 15.0.26430.6
Description : Microsoft DevOps solution for productivity and coordination
across teams of any size
DisplayName : Visual Studio Enterprise 2017
Id : e4f83d45
InstallDate : System.Runtime.InteropServices.ComTypes.FILETIME
Name : VisualStudio/15.4.0+27004.2002
Path : C:\Program Files (x86)\Microsoft Visual Studio\2017\Enterprise
Version : 15.4.27004.2002
VersionString : 15.4.27004.2002
Testing leaf: 'C:\Program Files (x86)\Microsoft Visual Studio\2017\TestAgent\Common7\IDE\CommonExtensions\Microsoft\TestWindow\vstest.console.exe'
Exists.
Working folder: c:\agent\_work\11\s
Executing C:\Program Files (x86)\Microsoft Visual Studio\2017\TestAgent\Common7\IDE\CommonExtensions\Microsoft\TestWindow\vstest.console.exe "c:\agent\_work\11\s\*******.EDI\*******.EDI.Tests\bin\Release\*******.EDI.Tests.dll" "c:\agent\_work\11\s\*******.EDI\*******.EDI\packages\FluentAssertions.4.19.4\lib\sl5\Microsoft.VisualStudio.QualityTools.UnitTesting.Silverlight.dll" "c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\_common\cs\Microsoft.VisualStudio.TestPlatform.MSTest.TestAdapter.resources.dll" "c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\_common\cs\Microsoft.VisualStudio.TestPlatform.MSTestAdapter.PlatformServices.resources.dll" "c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\_common\cs\Microsoft.VisualStudio.TestPlatform.TestFramework.resources.dll" "c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\_common\de\Microsoft.VisualStudio.TestPlatform.MSTest.TestAdapter.resources.dll" "c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\_common\de\Microsoft.VisualStudio.TestPlatform.MSTestAdapter.PlatformServices.resources.dll" "c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\_common\de\Microsoft.VisualStudio.TestPlatform.TestFramework.resources.dll" "c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\_common\es\Microsoft.VisualStudio.TestPlatform.MSTest.TestAdapter.resources.dll" "c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\_common\es\Microsoft.VisualStudio.TestPlatform.MSTestAdapter.PlatformServices.resources.dll" "c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\_common\es\Microsoft.VisualStudio.TestPlatform.TestFramework.resources.dll" "c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\_common\fr\Microsoft.VisualStudio.TestPlatform.MSTest.TestAdapter.resources.dll" "c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\_common\fr\Microsoft.VisualStudio.TestPlatform.MSTestAdapter.PlatformServices.resources.dll" "c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\_common\fr\Microsoft.VisualStudio.TestPlatform.TestFramework.resources.dll" "c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\_common\it\Microsoft.VisualStudio.TestPlatform.MSTest.TestAdapter.resources.dll" "c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\_common\it\Microsoft.VisualStudio.TestPlatform.MSTestAdapter.PlatformServices.resources.dll" "c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\_common\it\Microsoft.VisualStudio.TestPlatform.TestFramework.resources.dll" "c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\_common\ja\Microsoft.VisualStudio.TestPlatform.MSTest.TestAdapter.resources.dll" "c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\_common\ja\Microsoft.VisualStudio.TestPlatform.MSTestAdapter.PlatformServices.resources.dll" "c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\_common\ja\Microsoft.VisualStudio.TestPlatform.TestFramework.resources.dll" "c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\_common\ko\Microsoft.VisualStudio.TestPlatform.MSTest.TestAdapter.resources.dll" "c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\_common\ko\Microsoft.VisualStudio.TestPlatform.MSTestAdapter.PlatformServices.resources.dll" "c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\_common\ko\Microsoft.VisualStudio.TestPlatform.TestFramework.resources.dll" "c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\_common\Microsoft.VisualStudio.TestPlatform.MSTest.TestAdapter.dll" "c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\_common\Microsoft.VisualStudio.TestPlatform.MSTestAdapter.PlatformServices.dll" "c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\_common\Microsoft.VisualStudio.TestPlatform.MSTestAdapter.PlatformServices.Interface.dll" "c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\_common\Microsoft.VisualStudio.TestPlatform.TestFramework.dll" "c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\_common\pl\Microsoft.VisualStudio.TestPlatform.MSTest.TestAdapter.resources.dll" "c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\_common\pl\Microsoft.VisualStudio.TestPlatform.MSTestAdapter.PlatformServices.resources.dll" "c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\_common\pl\Microsoft.VisualStudio.TestPlatform.TestFramework.resources.dll" "c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\_common\pt\Microsoft.VisualStudio.TestPlatform.MSTest.TestAdapter.resources.dll" "c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\_common\pt\Microsoft.VisualStudio.TestPlatform.MSTestAdapter.PlatformServices.resources.dll" "c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\_common\pt\Microsoft.VisualStudio.TestPlatform.TestFramework.resources.dll" "c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\_common\ru\Microsoft.VisualStudio.TestPlatform.MSTest.TestAdapter.resources.dll" "c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\_common\ru\Microsoft.VisualStudio.TestPlatform.MSTestAdapter.PlatformServices.resources.dll" "c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\_common\ru\Microsoft.VisualStudio.TestPlatform.TestFramework.resources.dll" "c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\_common\tr\Microsoft.VisualStudio.TestPlatform.MSTest.TestAdapter.resources.dll" "c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\_common\tr\Microsoft.VisualStudio.TestPlatform.MSTestAdapter.PlatformServices.resources.dll" "c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\_common\tr\Microsoft.VisualStudio.TestPlatform.TestFramework.resources.dll" "c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\_common\zh-Hans\Microsoft.VisualStudio.TestPlatform.MSTest.TestAdapter.resources.dll" "c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\_common\zh-Hans\Microsoft.VisualStudio.TestPlatform.MSTestAdapter.PlatformServices.resources.dll" "c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\_common\zh-Hans\Microsoft.VisualStudio.TestPlatform.TestFramework.resources.dll" "c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\_common\zh-Hant\Microsoft.VisualStudio.TestPlatform.MSTest.TestAdapter.resources.dll" "c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\_common\zh-Hant\Microsoft.VisualStudio.TestPlatform.MSTestAdapter.PlatformServices.resources.dll" "c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\_common\zh-Hant\Microsoft.VisualStudio.TestPlatform.TestFramework.resources.dll" "c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\netstandard1.0\Microsoft.VisualStudio.TestPlatform.MSTestAdapter.PlatformServices.dll" "c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\uap10.0\Microsoft.VisualStudio.TestPlatform.MSTestAdapter.PlatformServices.dll" "c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestFramework.1.1.11\lib\dotnet\Microsoft.VisualStudio.TestPlatform.TestFramework.dll" "c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestFramework.1.1.11\lib\dotnet\Microsoft.VisualStudio.TestPlatform.TestFramework.Extensions.dll" "c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestFramework.1.1.11\lib\net45\Microsoft.VisualStudio.TestPlatform.TestFramework.dll" "c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestFramework.1.1.11\lib\net45\Microsoft.VisualStudio.TestPlatform.TestFramework.Extensions.dll" "c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestFramework.1.1.11\lib\netcoreapp1.0\Microsoft.VisualStudio.TestPlatform.TestFramework.dll" "c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestFramework.1.1.11\lib\netcoreapp1.0\Microsoft.VisualStudio.TestPlatform.TestFramework.Extensions.dll" "c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestFramework.1.1.11\lib\uap10.0\Microsoft.VisualStudio.TestPlatform.TestFramework.dll" "c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestFramework.1.1.11\lib\uap10.0\Microsoft.VisualStudio.TestPlatform.TestFramework.Extensions.dll" /EnableCodeCoverage /logger:trx /TestAdapterPath:"c:\agent\_work\11\s"
Microsoft (R) Test Execution Command Line Tool Version 15.0.26228.0
Copyright (c) Microsoft Corporation. All rights reserved.
Starting test execution, please wait...
Warning: Using Isolation mode to run the tests as diagnostic data adapters were enabled in the runsettings. Use the /inIsolation parameter to suppress this warning.
Warning: Unable to load types from the test source 'c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\uap10.0\Microsoft.VisualStudio.TestPlatform.MSTestAdapter.PlatformServices.dll'. Some or all of the tests in this source may not be discovered.
Warning: Input string was not in a correct format.
Warning: Input string was not in a correct format.
Warning: Input string was not in a correct format.
Warning: Input string was not in a correct format.
Warning: Input string was not in a correct format.
Warning: Unable to load types from the test source 'c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\_common\Microsoft.VisualStudio.TestPlatform.MSTestAdapter.PlatformServices.dll'. Some or all of the tests in this source may not be discovered.
Warning: No test is available in c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\_common\zh-Hans\Microsoft.VisualStudio.TestPlatform.TestFramework.resources.dll c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\_common\zh-Hans\Microsoft.VisualStudio.TestPlatform.MSTestAdapter.PlatformServices.resources.dll c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\_common\zh-Hans\Microsoft.VisualStudio.TestPlatform.MSTest.TestAdapter.resources.dll c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\_common\tr\Microsoft.VisualStudio.TestPlatform.TestFramework.resources.dll c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\_common\ru\Microsoft.VisualStudio.TestPlatform.TestFramework.resources.dll c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\_common\tr\Microsoft.VisualStudio.TestPlatform.MSTest.TestAdapter.resources.dll c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\_common\zh-Hant\Microsoft.VisualStudio.TestPlatform.MSTest.TestAdapter.resources.dll c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\_common\ru\Microsoft.VisualStudio.TestPlatform.MSTestAdapter.PlatformServices.resources.dll c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\_common\ru\Microsoft.VisualStudio.TestPlatform.MSTest.TestAdapter.resources.dll c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\_common\tr\Microsoft.VisualStudio.TestPlatform.MSTestAdapter.PlatformServices.resources.dll c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\_common\zh-Hant\Microsoft.VisualStudio.TestPlatform.MSTestAdapter.PlatformServices.resources.dll c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\uap10.0\Microsoft.VisualStudio.TestPlatform.MSTestAdapter.PlatformServices.dll c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\netstandard1.0\Microsoft.VisualStudio.TestPlatform.MSTestAdapter.PlatformServices.dll c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\_common\pt\Microsoft.VisualStudio.TestPlatform.TestFramework.resources.dll c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestFramework.1.1.11\lib\dotnet\Microsoft.VisualStudio.TestPlatform.TestFramework.dll c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestFramework.1.1.11\lib\dotnet\Microsoft.VisualStudio.TestPlatform.TestFramework.Extensions.dll c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestFramework.1.1.11\lib\net45\Microsoft.VisualStudio.TestPlatform.TestFramework.dll c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestFramework.1.1.11\lib\netcoreapp1.0\Microsoft.VisualStudio.TestPlatform.TestFramework.dll c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestFramework.1.1.11\lib\netcoreapp1.0\Microsoft.VisualStudio.TestPlatform.TestFramework.Extensions.dll c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestFramework.1.1.11\lib\uap10.0\Microsoft.VisualStudio.TestPlatform.TestFramework.dll c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestFramework.1.1.11\lib\uap10.0\Microsoft.VisualStudio.TestPlatform.TestFramework.Extensions.dll c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\_common\zh-Hant\Microsoft.VisualStudio.TestPlatform.TestFramework.resources.dll c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\_common\pt\Microsoft.VisualStudio.TestPlatform.MSTestAdapter.PlatformServices.resources.dll c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\_common\pl\Microsoft.VisualStudio.TestPlatform.TestFramework.resources.dll c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\_common\cs\Microsoft.VisualStudio.TestPlatform.MSTest.TestAdapter.resources.dll c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\_common\cs\Microsoft.VisualStudio.TestPlatform.MSTestAdapter.PlatformServices.resources.dll c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\_common\cs\Microsoft.VisualStudio.TestPlatform.TestFramework.resources.dll c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\_common\de\Microsoft.VisualStudio.TestPlatform.MSTest.TestAdapter.resources.dll c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\_common\de\Microsoft.VisualStudio.TestPlatform.MSTestAdapter.PlatformServices.resources.dll c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\_common\de\Microsoft.VisualStudio.TestPlatform.TestFramework.resources.dll c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\_common\es\Microsoft.VisualStudio.TestPlatform.MSTest.TestAdapter.resources.dll c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\_common\es\Microsoft.VisualStudio.TestPlatform.MSTestAdapter.PlatformServices.resources.dll c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\_common\es\Microsoft.VisualStudio.TestPlatform.TestFramework.resources.dll c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\_common\fr\Microsoft.VisualStudio.TestPlatform.MSTest.TestAdapter.resources.dll c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\_common\fr\Microsoft.VisualStudio.TestPlatform.MSTestAdapter.PlatformServices.resources.dll c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\_common\fr\Microsoft.VisualStudio.TestPlatform.TestFramework.resources.dll c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\_common\pt\Microsoft.VisualStudio.TestPlatform.MSTest.TestAdapter.resources.dll c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\_common\it\Microsoft.VisualStudio.TestPlatform.MSTest.TestAdapter.resources.dll c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\_common\it\Microsoft.VisualStudio.TestPlatform.TestFramework.resources.dll c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\_common\ja\Microsoft.VisualStudio.TestPlatform.MSTest.TestAdapter.resources.dll c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\_common\ja\Microsoft.VisualStudio.TestPlatform.MSTestAdapter.PlatformServices.resources.dll c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\_common\ja\Microsoft.VisualStudio.TestPlatform.TestFramework.resources.dll c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\_common\ko\Microsoft.VisualStudio.TestPlatform.MSTest.TestAdapter.resources.dll c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\_common\ko\Microsoft.VisualStudio.TestPlatform.MSTestAdapter.PlatformServices.resources.dll c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\_common\ko\Microsoft.VisualStudio.TestPlatform.TestFramework.resources.dll c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\_common\Microsoft.VisualStudio.TestPlatform.MSTest.TestAdapter.dll c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\_common\Microsoft.VisualStudio.TestPlatform.MSTestAdapter.PlatformServices.Interface.dll c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\_common\Microsoft.VisualStudio.TestPlatform.TestFramework.dll c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\_common\pl\Microsoft.VisualStudio.TestPlatform.MSTest.TestAdapter.resources.dll c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\_common\pl\Microsoft.VisualStudio.TestPlatform.MSTestAdapter.PlatformServices.resources.dll c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\_common\it\Microsoft.VisualStudio.TestPlatform.MSTestAdapter.PlatformServices.resources.dll c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestFramework.1.1.11\lib\net45\Microsoft.VisualStudio.TestPlatform.TestFramework.Extensions.dll c:\agent\_work\11\s\*******.EDI\*******.EDI.Tests\bin\Release\*******.EDI.Tests.dll c:\agent\_work\11\s\*******.Web\*******.Web\packages\MSTest.TestAdapter.1.1.11\build\_common\Microsoft.VisualStudio.TestPlatform.MSTestAdapter.PlatformServices.dll c:\agent\_work\11\s\*******.EDI\*******.EDI\packages\FluentAssertions.4.19.4\lib\sl5\Microsoft.VisualStudio.QualityTools.UnitTesting.Silverlight.dll. Make sure that installed test discoverers & executors, platform & framework version settings are appropriate and try again.
Attachments:
c:\agent\_work\11\s\TestResults\e806ae8a-20fe-40d7-956e-90b827a56c83\Dwainwright_ASSODOPDV01 2017-10-23 15_39_33.coverage
Information: Additionally, you can try specifying '/UseVsixExtensions' command if the test discoverer & executor is installed on the machine as vsix extensions and your installation supports vsix extensions. Example: vstest.console.exe myTests.dll /UseVsixExtensions:true
##[warning]No results found to publish.
##[section]Finishing: Test Assemblies **\*test*.dll;-:**\obj\**
The Build Step for full framework
How can i set up TFS so that the tests are actually ran, and more so, the build stops if any test fails.
Further info:
I have VS 2017 installed on the build server too.
The tests are written in NUnit. Not sure if something else needs adding to the build server. Almost looks as though the build server is trying to use MSTest; i see some references to MSTestAdapter
VSTest task cannot run .NET core tests as it uses the Test platform version 1. To run .NET core tests, we recommend using the .NET core task with the test command.
Reference https://github.com/Microsoft/vsts-tasks/issues/5066
As a workaroun you can manually invoke vstest.console.exe from folder C:\Program Files (x86)\Microsoft Visual Studio\2017\Enterprise\Common7\IDE\Extensions\TestPlatform\ and provide /Framework:FrameworkCore10.
C:\Program Files (x86)>dir vstest.console.exe /s
Volume in drive C is Windows
Volume Serial Number is 0835-B24B
Directory of C:\Program Files (x86)\Microsoft Visual Studio\2017\Enterprise\Com
mon7\IDE\CommonExtensions\Microsoft\TestWindow
10/24/2017 02:55 PM 137,824 vstest.console.exe
1 File(s) 137,824 bytes
Directory of C:\Program Files (x86)\Microsoft Visual Studio\2017\Enterprise\Com
mon7\IDE\Extensions\TestPlatform
09/04/2017 12:09 PM 133,240 vstest.console.exe
1 File(s) 133,240 bytes
Reference https://github.com/Microsoft/vstest/issues/579#issuecomment-339263411
UPDATE:
Make sure you are not missing and dependancies.
Check the packages.config, it should be similar as below:
<?xml version="1.0" encoding="utf-8"?>
<packages>
<package id="MSTest.TestAdapter" version="1.1.11" targetFramework="net452" />
<package id="MSTest.TestFramework" version="1.1.11" targetFramework="net452" />
</packages>
With Visual Studio 2017 Community I have created a solution with a F# library project (regular, not PCL) targeting the .NET 4.5.2 framework and the F# 4.1 (FSharp.Core, 4.4.1.0) runtime. Visual Studio added for me the NuGet reference to System.ValueType (4.3.0) by default.
The only code in this project is the following which is using System.ValueType:
type TupleCreator() =
member this.Create x =
System.ValueTuple.Create(x)
Building the project locally works fine, unfortunately this is not the case with VSTS. I have a build definition (with default agent queue set to Hosted VS2017) with a NuGet restore step and a build solution step (with Visual Studio Version set to Latest).
When the build runs it succeeds in restoring the nuget packages:
##[section]Starting: NuGet restore **\*.sln
=================================================================
Task : NuGet Installer
Description : Installs or restores missing NuGet packages
Version : 0.2.31
Author : Microsoft Corporation
=================================================================
[command]C:\Windows\system32\chcp.com 65001
Active code page: 65001
Detected NuGet version 3.3.0.212 / 3.3.0
SYSTEMVSSCONNECTION exists true
To connect to NuGet feeds hosted in your Team Services account/TFS project collection on this build agent, edit your build definition to choose a higher version of nuget or specify a path to a NuGet.config containing the package sources you wish to use.
[command]d:\a\_tasks\NuGetInstaller_333b11bd-d341-40d9-afcf-b32d5ce6f23b\0.2.31\node_modules\nuget-task-common\NuGet\3.3.0\NuGet.exe restore -NonInteractive d:\a\3\s\Apps\Sandbox\FSharpWithNugetDemo\FSharpWithNugetDemo.sln
MSBuild auto-detection: using msbuild version '4.0' from 'C:\Windows\Microsoft.NET\Framework\v4.0.30319'.
Feeds used:
C:\Users\buildguest\AppData\Local\NuGet\Cache
https://api.nuget.org/v3/index.json
Restoring NuGet package System.ValueTuple.4.3.0.
Adding package 'System.ValueTuple.4.3.0' to folder 'd:\a\3\s\Apps\Sandbox\FSharpWithNugetDemo\packages'
Added package 'System.ValueTuple.4.3.0' to folder 'd:\a\3\s\Apps\Sandbox\FSharpWithNugetDemo\packages'
##[section]Finishing: NuGet restore **\*.sln
The build step then yields the following log:
##[section]Starting: Build solution $/tfs1/Apps/Sandbox/FSharpWithNugetDemo/FSharpWithNugetDemo.sln
==============================================================================
Task : Visual Studio Build
Description : Build with MSBuild and set the Visual Studio version property
Version : 1.117.0
Author : Microsoft Corporation
Help : [More Information](https://go.microsoft.com/fwlink/?LinkID=613727)
==============================================================================
##[command]"D:\a\_tasks\VSBuild_71a9a2d3-a98a-4caa-96ab-affca411ecda\1.117.0\ps_modules\MSBuildHelpers\vswhere.exe" -version [15.0,15.1) -latest -format json
##[command]"C:\Program Files (x86)\Microsoft Visual Studio\2017\Enterprise\MSBuild\15.0\Bin\msbuild.exe" "d:\a\3\s\Apps\Sandbox\FSharpWithNugetDemo\FSharpWithNugetDemo.sln" /nologo /nr:false /dl:CentralLogger,"D:\a\_tasks\VSBuild_71a9a2d3-a98a-4caa-96ab-affca411ecda\1.117.0\ps_modules\MSBuildHelpers\Microsoft.TeamFoundation.DistributedTask.MSBuild.Logger.dll";"RootDetailId=d08ecee6-b628-4743-9e80-d31a64026956|SolutionDir=d:\a\3\s\Apps\Sandbox\FSharpWithNugetDemo"*ForwardingLogger,"D:\a\_tasks\VSBuild_71a9a2d3-a98a-4caa-96ab-affca411ecda\1.117.0\ps_modules\MSBuildHelpers\Microsoft.TeamFoundation.DistributedTask.MSBuild.Logger.dll" /p:TreatWarningsAsErrors=False /p:platform="any cpu" /p:configuration="debug" /p:VisualStudioVersion="15.0" /p:_MSDeployUserAgent="VSTS_1e91f890-819e-4329-aa62-069b62ae16d0_build_4_116"
Building the projects in this solution one at a time. To enable parallel build, please add the "/m" switch.
Build started 5/24/2017 6:32:52 PM.
Project "d:\a\3\s\Apps\Sandbox\FSharpWithNugetDemo\FSharpWithNugetDemo.sln" on node 1 (default targets).
ValidateSolutionConfiguration:
Building solution configuration "debug|any cpu".
Project "d:\a\3\s\Apps\Sandbox\FSharpWithNugetDemo\FSharpWithNugetDemo.sln" (1) is building "d:\a\3\s\Apps\Sandbox\FSharpWithNugetDemo\FSharpWithNugetDemo.fsproj" (2) on node 1 (default targets).
PrepareForBuild:
Creating directory "bin\Debug\".
Creating directory "obj\Debug\".
ResolveAssemblyReferences:
Primary reference "System.ValueTuple".
##[warning]C:\Program Files (x86)\Microsoft Visual Studio\2017\Enterprise\MSBuild\15.0\Bin\Microsoft.Common.CurrentVersion.targets(1964,5): Warning MSB3245: Could not resolve this reference. Could not locate the assembly "System.ValueTuple". Check to make sure the assembly exists on disk. If this reference is required by your code, you may get compilation errors.
C:\Program Files (x86)\Microsoft Visual Studio\2017\Enterprise\MSBuild\15.0\Bin\Microsoft.Common.CurrentVersion.targets(1964,5): warning MSB3245: Could not resolve this reference. Could not locate the assembly "System.ValueTuple". Check to make sure the assembly exists on disk. If this reference is required by your code, you may get compilation errors. [d:\a\3\s\Apps\Sandbox\FSharpWithNugetDemo\FSharpWithNugetDemo.fsproj]
For SearchPath "{HintPathFromItem}".
Considered "..\..\Sandbox (local)\packages\System.ValueTuple.4.3.0\lib\netstandard1.0\System.ValueTuple.dll", but it didn't exist.
For SearchPath "{TargetFrameworkDirectory}".
Considered "C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.5.2\System.ValueTuple.winmd", but it didn't exist.
Considered "C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.5.2\System.ValueTuple.dll", but it didn't exist.
Considered "C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.5.2\System.ValueTuple.exe", but it didn't exist.
.
.
.
Considered "bin\Debug\System.ValueTuple.exe", but it didn't exist.
CoreCompile:
C:\Program Files (x86)\Microsoft SDKs\F#\4.1\Framework\v4.0\fsc.exe -o:obj\Debug\FSharpWithNugetDemo.dll
-g
--debug:full
--noframework
--define:DEBUG
--define:TRACE
--doc:bin\Debug\FSharpWithNugetDemo.XML
--optimize-
--tailcalls-
-r:C:\Program Files (x86)\Reference Assemblies\Microsoft\FSharp\.NETFramework\v4.0\4.4.1.0\FSharp.Core.dll
-r:C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.5.2\mscorlib.dll
-r:C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.5.2\System.Core.dll
-r:C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.5.2\System.dll
-r:C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.5.2\System.Numerics.dll
--target:library
--warn:3
--warnaserror:76
--fullpaths
--flaterrors
--subsystemversion:6.00
--highentropyva+
d:\a\_temp\.NETFramework,Version=v4.5.2.AssemblyAttributes.fs
AssemblyInfo.fs
Library1.fs
##[error]Apps\Sandbox\FSharpWithNugetDemo\Library1.fs(5,12): Error FS0039: The value, constructor, namespace or type 'ValueTuple' is not defined. Maybe you want one of the following: ValueType
d:\a\3\s\Apps\Sandbox\FSharpWithNugetDemo\Library1.fs(5,12): error FS0039: The value, constructor, namespace or type 'ValueTuple' is not defined. Maybe you want one of the following: ValueType [d:\a\3\s\Apps\Sandbox\FSharpWithNugetDemo\FSharpWithNugetDemo.fsproj]
Done Building Project "d:\a\3\s\Apps\Sandbox\FSharpWithNugetDemo\FSharpWithNugetDemo.fsproj" (default targets) -- FAILED.
Done Building Project "d:\a\3\s\Apps\Sandbox\FSharpWithNugetDemo\FSharpWithNugetDemo.sln" (default targets) -- FAILED.
Build FAILED.
"d:\a\3\s\Apps\Sandbox\FSharpWithNugetDemo\FSharpWithNugetDemo.sln" (default target) (1) ->
"d:\a\3\s\Apps\Sandbox\FSharpWithNugetDemo\FSharpWithNugetDemo.fsproj" (default target) (2) ->
(ResolveAssemblyReferences target) ->
C:\Program Files (x86)\Microsoft Visual Studio\2017\Enterprise\MSBuild\15.0\Bin\Microsoft.Common.CurrentVersion.targets(1964,5): warning MSB3245: Could not resolve this reference. Could not locate the assembly "System.ValueTuple". Check to make sure the assembly exists on disk. If this reference is required by your code, you may get compilation errors. [d:\a\3\s\Apps\Sandbox\FSharpWithNugetDemo\FSharpWithNugetDemo.fsproj]
"d:\a\3\s\Apps\Sandbox\FSharpWithNugetDemo\FSharpWithNugetDemo.sln" (default target) (1) ->
"d:\a\3\s\Apps\Sandbox\FSharpWithNugetDemo\FSharpWithNugetDemo.fsproj" (default target) (2) ->
(CoreCompile target) ->
d:\a\3\s\Apps\Sandbox\FSharpWithNugetDemo\Library1.fs(5,12): error FS0039: The value, constructor, namespace or type 'ValueTuple' is not defined. Maybe you want one of the following: ValueType [d:\a\3\s\Apps\Sandbox\FSharpWithNugetDemo\FSharpWithNugetDemo.fsproj]
1 Warning(s)
1 Error(s)
Time Elapsed 00:00:06.14
##[error]Process 'msbuild.exe' exited with code '1'.
This is not an issue with System.ValueType because the build process is unable to build with references to any nuget packages. This is also not an issue with my VSTS because my C# projects with NuGet references get built fine.
What is wrong with my F# project? Are there additional steps to be taken in order to enable NuGet in F# projects on VSTS?
EDIT
I just compared the output of the CoreCompile section with what is printed in Visual Studio. In Visual Studio it says:
C:\Program Files (x86)\Microsoft SDKs\F#\4.1\Framework\v4.0\fsc.exe -o:obj\Debug\FSharpWithNugetDemo.dll
-g
--debug:full
--noframework
--define:DEBUG
--define:TRACE
--doc:bin\Debug\FSharpWithNugetDemo.XML
--optimize-
--tailcalls-
-r:C:\Program Files (x86)\Reference Assemblies\Microsoft\FSharp\.NETFramework\v4.0\4.4.1.0\FSharp.Core.dll
-r:C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.5.2\mscorlib.dll
-r:C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.5.2\System.Core.dll
-r:C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.5.2\System.dll
-r:C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.5.2\System.Numerics.dll
-r:D:\Projects\Sandbox\packages\System.ValueTuple.4.3.0\lib\netstandard1.0\System.ValueTuple.dll
.
.
.
--target:library
--warn:3
--warnaserror:76
--vserrors
--utf8output
--fullpaths
--flaterrors
--subsystemversion:6.00
--highentropyva+
C:\Users\David\AppData\Local\Temp\.NETFramework,Version=v4.5.2.AssemblyAttributes.fs
AssemblyInfo.fs
Library1.fs
FSharpWithNugetDemo -> D:\Projekte\VisualStudio.com\sphereutfs\Dev\Apps\Sandbox\FSharpWithNugetDemo\bin\Debug\FSharpWithNugetDemo.dll
The difference is that there is a -r: line with a path to the System.ValueTuple.dll obtained from NuGet which is missing in the log of the VSTS build. How can I tell the VSTS build to include this reference when compiling?
This is caused the setting in your FSharpWithNugetDemo.fsproj file. You set the path for System.ValueTuple as your local path:
<Reference Include="System.ValueTuple">
<HintPath>..\..\Sandbox (local)\packages\System.ValueTuple.4.3.0\lib\netstandard1.0\System.ValueTuple.dll</HintPath>
</Reference>
It should be use relate path so that when it build by VSTS, System.ValueTuple will be searched in $(build.sourcesdirectory):
<Reference Include="System.ValueTuple">
<HintPath>..\packages\System.ValueTuple.4.3.0\lib\netstandard1.0\System.ValueTuple.dll</HintPath>
</Reference>
I need to use TfvcTemplate.12.xaml because of its Pre and Post build script execution support and I need to run a Powershell script as PreBuild event.
On TFS 2013, Building a Wix project using old DefaultTemplate.xaml works fine. While trying to build using new default template TfvcTemplate.12.xaml builds the csharp project fine, but Wix is unable to find its files, while files are present at same location.
Here is Wix code:
<?xml version="1.0" encoding="utf-8"?>
<Wix xmlns="http://schemas.microsoft.com/wix/2006/wi">
<?define SourceDir=$(var.OutDir)?>
<?warning **************** Target=$(var.TargetDir) ***********?>
<?warning **************** src=$(var.SourceDir) **************?>
<Product Id="*" Language="1033" Manufacturer="Test" Name="Testing" UpgradeCode="DB7DAC5A-ED29-45E6-8029-89F6486A9ACA" Version="1.0.0.0">
<Package Compressed="yes" InstallerVersion="200" Platform="x64" />
<Directory Id="TARGETDIR" Name="SourceDir">
<Directory Id="ProgramFilesFolder" Name="ProgFiles">
<Directory Id="bin" Name="bin">
<Component Id="AddProjToSln.exe" Guid="*">
<File Id="AddProjToSln.exe" KeyPath="yes" Source="$(var.SourceDir)AddProjToSln.exe" />
</Component>
<Component Id="AddProjToSln.exe.config" Guid="*">
<File Id="AddProjToSln.exe.config" KeyPath="yes" Source="$(var.SourceDir)AddProjToSln.exe.config" />
</Component>
</Directory>
</Directory>
</Directory>
<Feature Id="ProductFeature" Level="1" Title="TestFe">
<ComponentGroupRef Id="Testing" />
</Feature>
<Media Id="1" Cabinet="product.cab" EmbedCab="yes" />
</Product>
<Fragment>
<ComponentGroup Id="Testing">
<ComponentRef Id="AddProjToSln.exe" />
<ComponentRef Id="AddProjToSln.exe.config" />
</ComponentGroup>
</Fragment>
</Wix>
Here is the log from TFS:
Build started 10/13/2014 5:24:15 PM.
1>Project "D:\Builds\31\47\src\MyComp\Playground\MyUser\Utilities\VisualStudio\AddProjToSln.sln"
on node 1 (default targets).
1>ValidateSolutionConfiguration:
Building solution configuration "Debug|Any CPU".
1>Project "D:\Builds\31\47\src\MyComp\Playground\MyUser\Utilities\VisualStudio\AddProjToSln.sln"
(1) is building
"D:\Builds\31\47\src\MyComp\Playground\MyUser\Utilities\VisualStudio\AddProjToSln\AddProjToSln.csproj"
(2) on node 1 (default targets).
2>PrepareForBuild:
Creating directory "obj\Debug\".
1>Project "D:\Builds\31\47\src\MyComp\Playground\MyUser\Utilities\VisualStudio\AddProjToSln.sln"
(1) is building
"D:\Builds\31\47\src\MyComp\Playground\MyUser\Utilities\VisualStudio\TestInstall\test_install.wixproj"
(3) on node 2 (default targets).
3>PrepareForBuild:
Creating directory "obj\Debug\".
Compile:
C:\Program Files (x86)\WiX Toolset v3.8\bin\candle.exe -dDebug -d"DevEnvDir=Undefined if not building from within Visual Studio"
-dSolutionDir=D:\Builds\31\47\src\MyComp\Playground\MyUser\Utilities\VisualStudio\
-dSolutionExt=.sln -dSolutionFileName=AddProjToSln.sln -dSolutionName=AddProjToSln -dSolutionPath=D:\Builds\31\47\src\MyComp\Playground\MyUser\Utilities\VisualStudio\AddProjToSln.sln
-dConfiguration=Debug -dOutDir=D:\Builds\31\47\bin\ -dPlatform=x86 -dProjectDir=D:\Builds\31\47\src\MyComp\Playground\MyUser\Utilities\VisualStudio\TestInstall\
-dProjectExt=.wixproj -dProjectFileName=test_install.wixproj -dProjectName=test_install -dProjectPath=D:\Builds\31\47\src\MyComp\Playground\MyUser\Utilities\VisualStudio\TestInstall\test_install.wixproj
-dTargetDir=D:\Builds\31\47\bin\ -dTargetExt=.msi -dTargetFileName=test.msi -dTargetName=test -dTargetPath=D:\Builds\31\47\bin\test.msi -out obj\Debug\ -arch x86 Product.wxs
3>D:\Builds\31\47\src\MyComp\Playground\MyUser\Utilities\VisualStudio\TestInstall\Product.wxs(4):
warning CNDL1096: **************** Target=D:\Builds\31\47\bin\
*********** [D:\Builds\31\47\src\MyComp\Playground\MyUser\Utilities\VisualStudio\TestInstall\test_install.wixproj]
3>D:\Builds\31\47\src\MyComp\Playground\MyUser\Utilities\VisualStudio\TestInstall\Product.wxs(5):
warning CNDL1096: **************** src=D:\Builds\31\47\bin\
************** [D:\Builds\31\47\src\MyComp\Playground\MyUser\Utilities\VisualStudio\TestInstall\test_install.wixproj]
Link:
C:\Program Files (x86)\WiX Toolset v3.8\bin\Light.exe -out D:\Builds\31\47\bin\test.msi -pdbout D:\Builds\31\47\bin\test.wixpdb
-cultures:null -contentsfile obj\Debug\test_install.wixproj.BindContentsFileListnull.txt
-outputsfile obj\Debug\test_install.wixproj.BindOutputsFileListnull.txt
-builtoutputsfile obj\Debug\test_install.wixproj.BindBuiltOutputsFileListnull.txt
-wixprojectfile D:\Builds\31\47\src\MyComp\Playground\MyUser\Utilities\VisualStudio\TestInstall\test_install.wixproj
obj\Debug\Product.wixobj
2>GenerateTargetFrameworkMonikerAttribute:
Skipping target "GenerateTargetFrameworkMonikerAttribute" because all output files are up-to-date with respect to the input
files.
3>D:\Builds\31\47\src\MyComp\Playground\MyUser\Utilities\VisualStudio\TestInstall\Product.wxs(12):
error LGHT0103: The system cannot find the file
'D:\Builds\31\47\bin\AddProjToSln.exe'.
[D:\Builds\31\47\src\MyComp\Playground\MyUser\Utilities\VisualStudio\TestInstall\test_install.wixproj]
3>D:\Builds\31\47\src\MyComp\Playground\MyUser\Utilities\VisualStudio\TestInstall\Product.wxs(15):
error LGHT0103: The system cannot find the file
'D:\Builds\31\47\bin\AddProjToSln.exe.config'.
[D:\Builds\31\47\src\MyComp\Playground\MyUser\Utilities\VisualStudio\TestInstall\test_install.wixproj]
3>Done Building Project "D:\Builds\31\47\src\MyComp\Playground\MyUser\Utilities\VisualStudio\TestInstall\test_install.wixproj"
(default targets) -- FAILED.
2>CoreCompile:
C:\Program Files (x86)\MSBuild\12.0\bin\amd64\Csc.exe /noconfig /nowarn:1701,1702 /nostdlib+ /platform:AnyCPU
/errorreport:prompt /warn:4 /main:AddProjToSln.Program /highentropyva+
/reference:"c:\Program Files (x86)\Microsoft Visual Studio
10.0\Common7\IDE\PublicAssemblies\envdte.dll" /reference:"c:\Program Files (x86)\Microsoft Visual Studio
10.0\Common7\IDE\PublicAssemblies\envdte100.dll" /reference:"c:\Program Files (x86)\Microsoft Visual Studio
10.0\Common7\IDE\PublicAssemblies\envdte80.dll" /reference:"c:\Program Files (x86)\Microsoft Visual Studio
10.0\Common7\IDE\PublicAssemblies\envdte90.dll" /reference:"C:\Program Files (x86)\Reference
Assemblies\Microsoft\Framework.NETFramework\v4.5\Microsoft.CSharp.dll"
/reference:"C:\Program Files (x86)\Reference
Assemblies\Microsoft\Framework.NETFramework\v4.5\Microsoft.VisualBasic.dll"
/reference:"C:\Program Files (x86)\Reference
Assemblies\Microsoft\Framework.NETFramework\v4.5\mscorlib.dll"
/reference:"C:\Program Files (x86)\Reference
Assemblies\Microsoft\Framework.NETFramework\v4.5\System.Core.dll"
/reference:"C:\Program Files (x86)\Reference
Assemblies\Microsoft\Framework.NETFramework\v4.5\System.Data.DataSetExtensions.dll"
/reference:"C:\Program Files (x86)\Reference
Assemblies\Microsoft\Framework.NETFramework\v4.5\System.Data.dll"
/reference:"C:\Program Files (x86)\Reference
Assemblies\Microsoft\Framework.NETFramework\v4.5\System.dll"
/reference:"C:\Program Files (x86)\Reference
Assemblies\Microsoft\Framework.NETFramework\v4.5\System.Windows.Forms.dll"
/reference:"C:\Program Files (x86)\Reference
Assemblies\Microsoft\Framework.NETFramework\v4.5\System.Xml.dll"
/reference:"C:\Program Files (x86)\Reference
Assemblies\Microsoft\Framework.NETFramework\v4.5\System.Xml.Linq.dll"
/debug+ /debug:full /filealign:512 /optimize-
/out:obj\Debug\AddProjToSln.exe /subsystemversion:6.00 /target:exe
/utf8output /win32icon:"Crystal_Clear_mimetype_recycled (2).ico"
Program.cs Properties\AssemblyInfo.cs
"C:\Users\tfsbuild\AppData\Local\Temp.NETFramework,Version=v4.5.AssemblyAttributes.cs"
_CopyAppConfigFile:
Copying file from "App.config" to "D:\Builds\31\47\bin\AddProjToSln.exe.config".
CopyFilesToOutputDirectory:
Copying file from "obj\Debug\AddProjToSln.exe" to "D:\Builds\31\47\bin\AddProjToSln.exe".
AddProjToSln -> D:\Builds\31\47\bin\AddProjToSln.exe
Copying file from "obj\Debug\AddProjToSln.pdb" to "D:\Builds\31\47\bin\AddProjToSln.pdb".
2>Done Building Project "D:\Builds\31\47\src\MyComp\Playground\MyUser\Utilities\VisualStudio\AddProjToSln\AddProjToSln.csproj"
(default targets).
1>Done Building Project "D:\Builds\31\47\src\MyComp\Playground\MyUser\Utilities\VisualStudio\AddProjToSln.sln"
(default targets) -- FAILED.
Build FAILED.
"D:\Builds\31\47\src\MyComp\Playground\MyUser\Utilities\VisualStudio\AddProjToSln.sln"
(default target) (1) ->
"D:\Builds\31\47\src\MyComp\Playground\MyUser\Utilities\VisualStudio\TestInstall\test_install.wixproj"
(default target) (3) ->
(Compile target) ->
D:\Builds\31\47\src\MyComp\Playground\MyUser\Utilities\VisualStudio\TestInstall\Product.wxs(4):
warning CNDL1096: **************** Target=D:\Builds\31\47\bin\
*********** [D:\Builds\31\47\src\MyComp\Playground\MyUser\Utilities\VisualStudio\TestInstall\test_install.wixproj]
D:\Builds\31\47\src\MyComp\Playground\MyUser\Utilities\VisualStudio\TestInstall\Product.wxs(5):
warning CNDL1096: **************** src=D:\Builds\31\47\bin\
************** [D:\Builds\31\47\src\MyComp\Playground\MyUser\Utilities\VisualStudio\TestInstall\test_install.wixproj]
"D:\Builds\31\47\src\MyComp\Playground\MyUser\Utilities\VisualStudio\AddProjToSln.sln"
(default target) (1) ->
"D:\Builds\31\47\src\MyComp\Playground\MyUser\Utilities\VisualStudio\TestInstall\test_install.wixproj"
(default target) (3) ->
(Link target) ->
D:\Builds\31\47\src\MyComp\Playground\MyUser\Utilities\VisualStudio\TestInstall\Product.wxs(12):
error LGHT0103: The system cannot find the file
'D:\Builds\31\47\bin\AddProjToSln.exe'.
[D:\Builds\31\47\src\MyComp\Playground\MyUser\Utilities\VisualStudio\TestInstall\test_install.wixproj]
D:\Builds\31\47\src\MyComp\Playground\MyUser\Utilities\VisualStudio\TestInstall\Product.wxs(15):
error LGHT0103: The system cannot find the file
'D:\Builds\31\47\bin\AddProjToSln.exe.config'.
[D:\Builds\31\47\src\MyComp\Playground\MyUser\Utilities\VisualStudio\TestInstall\test_install.wixproj]
2 Warning(s)
2 Error(s)
Time Elapsed 00:00:01.04
I verified multiple times that files are there and it builds without any problem at command line using MsBuild and Wix Tool set as well.
I'm unable to figure out why using TfvcTemplate.12.xaml, wix is unable to see its files while these are present intact there....
Any help would be really appreciated.
So, finally I was able to solve this after a whole day struggle. Like Digg a mountain and got a mice :).
Actually TfvcTemplate.12.xaml seems to be executing MsBuild with parallel processing enabled (/m), while in my VS Solution, Wix project was added independently i.e. in Build Order it was the last project to build, but I never set other projects as its dependencies. So MSBuild found that it has no dependency and ignored its Build Order and simply building it either on random order or as first project. So naturally installer project was unable to find its source files and so failing.
I verified this phenomena by removing /m:1 argument to MSBuild and declaring all other projects as Dependencies of Wix Project: i.e. in VS, PROJECT –> Project Dependencies. This caused MsBuild to build all other projects before Wix Project and now Wix is able to find its Source files properly…
Here is the screenshot for illustration:
I have the following coffeescript build file:
{
"cmd": ["coffee", "-c", "$file"]
, "selector": "source.coffee"
}
which when I try to run it gives me:
[Error 2] The system cannot find the file specified [cmd: [u'coffee',u'-c', u'W:\mayapp\myscript.coffee']]
[dir: W:\myapp]
[path: /usr/local/bin:C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System32\WindowsPowerShell\v1.0\;C:\Program
Files\Microsoft\Web Platform Installer\;C:\Program Files
(x86)\Microsoft ASP.NET\ASP.NET Web Pages\v1.0\;C:\Program Files
(x86)\Windows Kits\8.0\Windows Performance Toolkit\;C:\Program
Files\Microsoft SQL Server\110\Tools\Binn\;c:\Program Files
(x86)\Microsoft SQL Server\110\Tools\Binn\;c:\Program Files\Microsoft
SQL Server\110\DTS\Binn\;c:\Program Files (x86)\Microsoft SQL
Server\110\Tools\Binn\ManagementStudio\;c:\Program Files
(x86)\Microsoft Visual Studio
10.0\Common7\IDE\PrivateAssemblies\;c:\Program Files (x86)\Microsoft SQL Server\110\DTS\Binn\;C:\Program Files\TortoiseHg\;C:\Program Files
(x86)\nodejs\;C:\Program Files\Mercurial\;C:\Program
Files\TortoiseSVN\bin;C:\strawberry\c\bin;C:\strawberry\perl\site\bin;C:\strawberry\perl\bin;C:\Program
Files (x86)\Bitvise SSH
Client;C:\Chocolatey\bin;C:\Users\George\AppData\Roaming\npm\;C:\Program
Files\Gallio\bin;C:\Program Files (x86)\Git\cmd;] [Finished]
In powershell
coffee -c w:\myapp\myscript.coffee
runs just fine leading me to think it's the coffee file from npm that the build system cannot find. Yet notice the npm directory IS on my path and coffee.cmd is absolutely in that directory
W:> get-command coffee | select path
Path
----
C:\Users\George\AppData\Roaming\npm\coffee.cmd
my best guess is that the error is due to that linux path prefixed to sublime's path variable but I have no idea where that is coming from it is not in my path variable outside of sublime.
The solution was to use the command name with extension - sublime was unable to infer it.
So:
{
"cmd": ["coffee.cmd", "-c", "$file"]
, "selector": "source.coffee"
}