Почему библиотеки DLL не копируются в «TestResults \ Deploy_USER DATETIME»? - PullRequest
0 голосов
/ 19 сентября 2019

Я запускаю проект модульного тестирования, который не удается найти сборку.Ошибка, которую я вижу, это

GenericRegistration [0:05.379] Failed: Test method MyTestProject.PropertyRegistration.GenericRegistration threw exception: 
Test method MyTestProject.PropertyRegistration.GenericRegistration threw exception: 
System.IO.FileNotFoundException: Could not load file or assembly 'MyTestProject, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null' or one of its dependencies. The system cannot find the file specified.=== Pre-bind state information ===
LOG: DisplayName = MyTestProject, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null
 (Fully-specified)
LOG: Appbase = file:///.../TestResults/Deploy_USER 2019-09-19 16_41_30/Out
LOG: Initial PrivatePath = NULL
Calling assembly : (Unknown).
===
LOG: This bind MyAppts in default load context.
LOG: Found application configuration file (C:\repos\MyApp\MyApp\Source\App_Code\MyTestProject\bin\Debug\MyTestProject.dll.config).
LOG: Using application configuration file: C:\repos\MyApp\MyApp\Source\App_Code\MyTestProject\bin\Debug\MyTestProject.dll.config
LOG: Using host configuration file: 
LOG: Using machine configuration file from C:\Windows\Microsoft.NET\Framework\v4.0.30319\config\machine.config.
LOG: Policy not being applied to reference at this time (private, custom, partial, or location-based assembly bind).
LOG: Attempting download of new URL file:///.../TestResults/Deploy_USER 2019-09-19 16_41_30/Out/MyTestProject.DLL.
LOG: Attempting download of new URL file:///.../TestResults/Deploy_USER 2019-09-19 16_41_30/Out/MyTestProject/MyTestProject.DLL.
LOG: Attempting download of new URL file:///.../TestResults/Deploy_USER 2019-09-19 16_41_30/Out/MyTestProject.EXE.
LOG: Attempting download of new URL file:///.../TestResults/Deploy_USER 2019-09-19 16_41_30/Out/MyTestProject/MyTestProject.EXE.

    at System.Reflection.RuntimeAssembly._nLoad(AssemblyName fileName, String codeBase, Evidence assemblySecurity, RuntimeAssembly locationHint, StackCrawlMark& stackMark, IntPtr pPrivHostBinder, Boolean throwOnFileNotFound, Boolean forIntrospection, Boolean suppressSecurityChecks)
   at System.Reflection.RuntimeAssembly.nLoad(AssemblyName fileName, String codeBase, Evidence assemblySecurity, RuntimeAssembly locationHint, StackCrawlMark& stackMark, IntPtr pPrivHostBinder, Boolean throwOnFileNotFound, Boolean forIntrospection, Boolean suppressSecurityChecks)
   at System.Reflection.RuntimeAssembly.InternalLoadAssemblyName(AssemblyName assemblyRef, Evidence assemblySecurity, RuntimeAssembly reqAssembly, StackCrawlMark& stackMark, IntPtr pPrivHostBinder, Boolean throwOnFileNotFound, Boolean forIntrospection, Boolean suppressSecurityChecks)
   at System.Reflection.RuntimeAssembly.InternalLoad(String assemblyString, Evidence assemblySecurity, StackCrawlMark& stackMark, IntPtr pPrivHostBinder, Boolean forIntrospection)
   at System.Reflection.RuntimeAssembly.InternalLoad(String assemblyString, Evidence assemblySecurity, StackCrawlMark& stackMark, Boolean forIntrospection)
   at System.Reflection.Assembly.Load(String assemblyString)
   .
   .
   .

Если я вставлю точку останова в код, перейду в каталог Deploy_USER 2019-09-19 16_41_30/Out и вручную скопирую туда DLL, мои тесты будут работать.Почему файлы не копируются?

Добро пожаловать на сайт PullRequest, где вы можете задавать вопросы и получать ответы от других членов сообщества.
...