I have a net472 project containing unit tests using xUnit, which I develop in VS 2017. The project contains tests for an ASP.NET Core project.
I have migrated its packages.config
to the PackageReference
style using Visual Studio. It still builds in VS after migration, but building using MSBuild was broken. I get the following error:
Project "<solution-file-path>.sln" (2) is building "<project-file-path>.csproj" (14) on node 1 (default targets).
C:\Program Files (x86)\Microsoft Visual Studio\2017\Professional\MSBuild\Microsoft\NuGet\15.0\Microsoft.NuGet.targets(186,5): error : Your project file doesn't list 'win-x64' as a "RuntimeIdentifier". You should add 'win-x64' to the "RuntimeIdentifiers" property in your project file and then re-run NuGet restore. [<project-file-path>.csproj]
Done Building Project "<project-file-path>.csproj" (default targets) -- FAILED.
Anyone has a hint what the reason could be?
net472
project to test (and of course reference to) thecore
project? How can he compile at all? – Crossbar