Prevent MSTest from copying / deploying every dll

烈酒焚心 提交于 2019-12-03 16:36:25

问题


When running MSTest from Visual Studio - the unit test execution time is relatively quick.

When running MSTest from the command line, with /testsettings flag - the execution takes forever and that is because it spends 95% of its startup time copying the dll's to its Out folder. Is there a way to prevent this?

The default Local.testsettings in the project has no modifications to it (which also means it is empty). However, if I try to use that same file from the command line, MSTest complains about missing DLL's that the Unit Test reference.


回答1:


Have you tried disabling deployment in the test settings? When it is disabled, the tests should be run in-place rather than on copied assemblies. (See http://msdn.microsoft.com/en-us/library/ms182475.aspx for details.)




回答2:


try MSTest.exe /noisolation http://msdn.microsoft.com/en-US/library/ms182489.aspx



来源:https://stackoverflow.com/questions/6046466/prevent-mstest-from-copying-deploying-every-dll

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!