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

Notification

Icon
Error

Incorrect "Assemblies are being referenced from the build output"
Jonh04
#1 Posted : Friday, January 25, 2013 4:27:55 PM(UTC)
Rank: Member

Groups: Registered
Joined: 3/13/2012(UTC)
Posts: 20

Thanks: 1 times
Was thanked: 3 time(s) in 2 post(s)
The following assembly references have triggered this warning:
My:\path\bin\Debug\FakeItEasy.dll


<Reference Include="FakeItEasy, Version=1.7.4626.65, Culture=neutral, PublicKeyToken=eff28e2146d5fd2c, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion>
<HintPath>..\packages\FakeItEasy.1.7.4626.65\lib\NET40\FakeItEasy.dll</HintPath>
</Reference>
Remco
#2 Posted : Friday, January 25, 2013 10:33:25 PM(UTC)
Rank: NCrunch Developer

Groups: Administrators
Joined: 4/16/2011(UTC)
Posts: 7,144

Thanks: 959 times
Was thanked: 1290 time(s) in 1196 post(s)
Hi,

This message is kicked up by NCrunch when a referenced assembly resolved from MSBuild is being pulled from the same directory as one of the build outputs from another project. It analyses the physical output from MSBuild during a build of your project, and should be very accurate.

Note that MSBuild has enormous amounts of implicit logic when resolving references. For example, the 'HintPath' shown above is only a suggestion to the resolution that there may be an assembly at the location specified - it isn't considered a hard fact. If the file doesn't exist in the suggested location, MSBuild will continue to search around a large list of potential other locations in order to find the file. This means that MSBuild assembly resolution uses a 'best effort' approach in finding assemblies.

You can gain more information about how MSBuild is locating the incorrect assembly by invoking it on the command line. Simply go to the directory of the project containing the incorrect reference and try the following:

msbuild myproject.csproj /v:d

... This will output a detailed log that describes how MSBuild is locating each of the referenced assemblies. It isn't unusual to find some unpleasant surprises!


Cheers,

Remco
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.028 seconds.
Trial NCrunch
Take NCrunch for a spin
Do your fingers a favour and supercharge your testing workflow
Free Download