Hello,
I've installed the trial and am trying to give NCrunch a spin but it's failing to build a few projects in my solution.
I can't just post everything here, but the projects it is failing do so in result of missing references, specifically to UnityEngine. On VS I can build and run tests using these classLibraries as expected.
Here's a simple example of the Trace Output:
Quote:NCrunch: If you are experiencing problems in getting this project to build, have a look at
https://www.ncrunch.net/...ng_project-build-issues
ApiCompatibility.cs (1, 12): The type or namespace name 'UnityEngine' could not be found (are you missing a using directive or an assembly reference?)
WARNING - CallbackDispatcher.cs (304, 65): CS8625: Cannot convert null literal to non-nullable reference type.
WARNING - CallbackDispatcher.cs (308, 48): CS8625: Cannot convert null literal to non-nullable reference type.
WARNING - CallbackDispatcher.cs (328, 71): CS8625: Cannot convert null literal to non-nullable reference type.
WARNING - autogen\isteamgameserverugc.cs (35, 202): CS8625: Cannot convert null literal to non-nullable reference type.
WARNING - autogen\isteamugc.cs (36, 202): CS8625: Cannot convert null literal to non-nullable reference type.
I checked out the workspace built for these projects and noticed inconsistencies (not same project as above, but same references errors).
In my workspace:
Quote:
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<TargetFramework>netstandard2.1</TargetFramework>
<Nullable>enable</Nullable>
<AppendTargetFrameworkToOutputPath>false</AppendTargetFrameworkToOutputPath>
</PropertyGroup>
<ItemGroup>
<PackageReference Include="Unity3D" Version="2.1.3" />
</ItemGroup>
<ItemGroup>
<Reference Remove="$(UnityEnginePath)" />
<Reference Include="$(UnityEngineUIPath)" Private="true"/>
<Reference Include="$(UnityModulesPath)\UnityEngine.CoreModule.dll" Private="true" />
<Reference Include="$(UnityModulesPath)\UnityEngine.Physics2DModule.dll" Private="true" />
<Reference Include="$(UnityModulesPath)\UnityEngine.UIModule.dll" Private="true" />
</ItemGroup>
</Project>
In NCrunch workspace:
Quote:
<Project DefaultTargets="Build;NCrunchOutputDataQuery" Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<TargetFramework>netstandard2.1</TargetFramework>
<Nullable>enable</Nullable>
<AppendTargetFrameworkToOutputPath>false</AppendTargetFrameworkToOutputPath>
</PropertyGroup>
<ItemGroup>
<PackageReference Include="Unity3D" Version="2.1.3" />
</ItemGroup>
<ItemGroup>
<Reference Remove="$(UnityEnginePath)" />
<Reference Include="C:\Users\Adnecrias\AppData\Local\NCrunch\27788\11\_ncrunchreferences\UnityEngine.UI.dll">
<Private>true</Private>
</Reference>
</ItemGroup>
<Target Name="NCrunchOutputDataQuery" DependsOnTargets="">
<Message Text="#Expression_71bbb746da1f4c6fac5eb93c02efeb9e=$(OutDir)$(TargetName)$(TargetExt)" />
<Message Text="#Expression_d23a1c22f7884b6c988a7bb40a765c6b=$(Configuration)" />
<Message Text="#Expression_77d801ba68af488699837495e4c2ee13=$(TargetName)" />
<Message Text="#$TargetFrameworkDirectory=;$(TargetFrameworkDirectory)" />
<Message Text="#ReferencePath=;@(ReferencePath)" />
<Message Text="#ReferenceCopyLocalPaths=;@(ReferenceCopyLocalPaths)" />
<Message Text="#TargetPathWithTargetPlatformMoniker=;@(TargetPathWithTargetPlatformMoniker)" />
<Message Text="#CopiedFiles_SourceItemsToCopyToOutputDirectoryAlways=@(_SourceItemsToCopyToOutputDirectoryAlways)|@(_SourceItemsToCopyToOutputDirectoryAlways->'$(OutDir)%(TargetPath)')" Condition="'@(_SourceItemsToCopyToOutputDirectoryAlways->'$(OutDir)%(TargetPath)')'!=''" />
<Message Text="#CopiedFiles_SourceItemsToCopyToOutputDirectory=@(_SourceItemsToCopyToOutputDirectory)|@(_SourceItemsToCopyToOutputDirectory->'$(OutDir)%(TargetPath)')" Condition="'@(_SourceItemsToCopyToOutputDirectory->'$(OutDir)%(TargetPath)')'!=''" />
<Message Text="#CopiedFilesAllItemsFullPathWithTargetPath=@(AllItemsFullPathWithTargetPath)|@(AllItemsFullPathWithTargetPath->'$(OutDir)%(TargetPath)')" Condition="'@(AllItemsFullPathWithTargetPath->'$(OutDir)%(TargetPath)')'!=''" />
</Target>
<PropertyGroup>
<ProjectAssetsFile>C:\Users\Adnecrias\AppData\Local\NCrunch\27788\11\Vectrosity\obj\project.assets.json</ProjectAssetsFile>
</PropertyGroup>
</Project>
Why are the other references not showing up? Is it because they are private? The one to UnityEngine.UI.dll is at it has shown up.