Hi,
it indeed seems like a nuget dependency issue. And I fixed it, and I think you would want to hear what fixed my problem exactly...
At the same time as when I wrote down this issue, NCrunch also showed another warning - it could not create a test environment, as you also said in last message. Which is why I thought bringing this up might be interesting for you guys :)
If you hadn't brought this up, I would think of this as "just another warning" (which I usually just hide and do not handle)
The content of this warning was the following (I think many libraries are double ? Could be fixed, and I had to manually edit into the csharp project form. You might throw that syntax in for free instead of just listing, could certainly help :) )
<Quote>
NCrunch was unable to restore Nuget packages required to build a test environment for this solution, due to an error: The msbuild command returned exit code 1: "c:\program files\microsoft visual studio\2022\enterprise\MSBuild\Current\Bin\msbuild.exe" /t:Restore "C:\Users\dirk_\AppData\Local\NCrunch\21904\PackageRestore\restorePackages.csproj"
The following packages do not exist under the Nuget packages folder for the active user profile, yet they have been flagged by NCrunch as potentially needed for normal operation. NCrunch has attempted to restore these files via an MSBuild restore step, which has either failed or not returned the expected result. It's possible that these packages may not be needed for building projects or running tests in your environment. If you experience downstream problems with NCrunch on this solution, it is recommended you restore or download the packages manually.
Note that the restore of packages may fail if NCrunch is being hosted under a windows account that does not have sufficient rights to store files in the Nuget packages directory.System.Collections.NonGeneric v4.3.0
System.Runtime.Loader v4.3.0
System.Runtime.Serialization.Formatters v4.3.0
System.Runtime.Serialization.Primitives v4.3.0
System.Threading.Thread v4.3.0
System.Collections.NonGeneric v4.3.0
System.Runtime.Loader v4.3.0
System.Runtime.Serialization.Formatters v4.3.0
System.Runtime.Serialization.Primitives v4.3.0
System.Threading.Thread v4.3.0
System.Collections.NonGeneric v4.3.0
System.Runtime.Loader v4.3.0
System.Runtime.Serialization.Formatters v4.3.0
System.Runtime.Serialization.Primitives v4.3.0
System.Threading.Thread v4.3.0
System.Collections.NonGeneric v4.3.0
System.Runtime.Loader v4.3.0
System.Runtime.Serialization.Formatters v4.3.0
System.Runtime.Serialization.Primitives v4.3.0
System.Threading.Thread v4.3.0
System.Collections.NonGeneric v4.3.0
System.Runtime.Loader v4.3.0
System.Runtime.Serialization.Formatters v4.3.0
System.Runtime.Serialization.Primitives v4.3.0
System.Threading.Thread v4.3.0
System.Collections.NonGeneric v4.3.0
System.Runtime.Loader v4.3.0
System.Runtime.Serialization.Formatters v4.3.0
System.Runtime.Serialization.Primitives v4.3.0
System.Threading.Thread v4.3.0
System.Threading.Thread v4.0.0
System.Collections.NonGeneric v4.3.0
System.Collections.Specialized v4.3.0
System.ComponentModel v4.3.0
System.ComponentModel.Primitives v4.3.0
System.ComponentModel.TypeConverter v4.3.0
System.Runtime.Loader v4.3.0
System.Runtime.Serialization.Formatters v4.3.0
System.Runtime.Serialization.Primitives v4.3.0
System.Threading.Thread v4.3.0
System.Collections.NonGeneric v4.3.0
System.Collections.Specialized v4.3.0
System.ComponentModel v4.3.0
System.ComponentModel.Primitives v4.3.0
System.ComponentModel.TypeConverter v4.3.0
System.Runtime.Loader v4.3.0
System.Runtime.Serialization.Formatters v4.3.0
System.Runtime.Serialization.Primitives v4.3.0
System.Threading.Thread v4.3.0
System.Collections.NonGeneric v4.3.0
System.Collections.Specialized v4.3.0
System.ComponentModel v4.3.0
System.ComponentModel.Primitives v4.3.0
System.ComponentModel.TypeConverter v4.3.0
System.Runtime.Loader v4.3.0
System.Runtime.Serialization.Formatters v4.3.0
System.Runtime.Serialization.Primitives v4.3.0
System.Threading.Thread v4.3.0
System.Collections.NonGeneric v4.3.0
System.Collections.Specialized v4.3.0
System.ComponentModel v4.3.0
System.ComponentModel.Primitives v4.3.0
System.ComponentModel.TypeConverter v4.3.0
System.Runtime.Loader v4.3.0
System.Runtime.Serialization.Formatters v4.3.0
System.Runtime.Serialization.Primitives v4.3.0
System.Threading.Thread v4.3.0
xunit.runner.utility v2.4.1
System.Collections.NonGeneric v4.3.0
Click here to remove this error
</Quote>
So I continued what you told me to do to fix the issue.
Except the dummy libary I added, did not compile.
Look around and around. Then found my nuget sources were blank (only the vs offline nuget source)
I added nuget.org again (from here
https://stackoverflow.co...package-sources-missing)Then everything compiled.
Before compilation I removed my dummy library so that that issue "would remain the same".
But ncrunch then found everything.
So the dummy library in itself was not the catalyst in solving the issue, it was the catalyst in finding the source of the problems.
And it was the missing nuget source nuget.org . (in my case)
Thx for the tip...