问题
When I try to add a missing assembly to my project (for unit testing specifically) I noticed that the Assemblies tab is missing in the "Add Reference" dialog , see:
Is this a bug or a expected behavior? If it's expected how we are supposed to add the missing assemblies.
Note that I already tried through Nuget package manager and still didn't work.
回答1:
It is correct behaviour. The Assemblies tab is not available for Net Core projects. You wont be able to add assemblies from your system, because Net Core projects work with dependencies from Nuget. So, to add your references, you need to use the Nuget Package Manager instead.
- Right click your project
- Choose "Manage Nuget Packages"
- Find the package you want to add from the list
来源:https://stackoverflow.com/questions/56772625/cannot-add-assemblies-to-net-core-application-in-visual-studio-2019