Welcome Guest! To enable all features please Login or Register.

Notification

Icon
Error

Passing parameter to NCrunch.exe to be used for MsBuild?
GreenMoose
#1 Posted : Wednesday, December 7, 2016 10:46:15 AM(UTC)
Rank: Advanced Member

Groups: Registered
Joined: 6/17/2012(UTC)
Posts: 507

Thanks: 145 times
Was thanked: 66 time(s) in 64 post(s)
v2.26

Problem: We are targeting a framework not available on build machine (using TeamCity). This results in error
Code:

The reference assemblies for framework ".NETFramework,Version=v4.5.2" were not found. To resolve this, install the SDK or Targeting Pack for this framework version or retarget your application to a version of the framework for which you have the SDK or Targeting Pack installed. Note that assemblies will be resolved from the Global Assembly Cache (GAC) and will be used in place of reference assemblies. Therefore your assembly may not be correctly targeted for the framework you intend.


Solution with MSBuild: we use MSBuild parameter FrameworkPathOverride to be %DotNetFrameworkTargetingPack4.5.1_Path% in build step configuration System Properties (same alternative to use /p:FrameworkPathOverride=..) and it compiles fine.

With NCrunch.exe I do not now how to solve this, is there a way I can pass build parameters to it somehow?

Thanks.
GreenMoose
#2 Posted : Wednesday, December 7, 2016 10:50:09 AM(UTC)
Rank: Advanced Member

Groups: Registered
Joined: 6/17/2012(UTC)
Posts: 507

Thanks: 145 times
Was thanked: 66 time(s) in 64 post(s)
Never mind, I got it to work by using setting the property as an environment variable instead :)
1 user thanked GreenMoose for this useful post.
Remco on 12/7/2016(UTC)
Users browsing this topic
Guest
Forum Jump  
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.

YAF | YAF © 2003-2011, Yet Another Forum.NET
This page was generated in 0.015 seconds.
Trial NCrunch
Take NCrunch for a spin
Do your fingers a favour and supercharge your testing workflow
Free Download