How to use .testsettings
file running unit tests via vstest.console.exe
? I created empty visual studio solution, created empty unit test project, a
The solution is to use Microsoft.VisualStudio.QualityTools.UnitTestFramework
instead of Microsoft.VisualStudio.TestPlatform.TestFramework
which is added to your unit test project by Visual Studio by default. So you can remove two packages via NuGet
. You should delete MSTest.TestAdapter
and MSTest.TestFramework
and install Microsoft.VisualStudio.QualityTools.UnitTestFramework.Updated
. Your unit tests will be discovered after these steps.
Also you can read the following useful article about test framework MSTest V2.
I had the similar problem and I have resolved it the following way:
Go to Test -> Test Settings
Uncheck the \..\..projectTestSettings.testsettings
file
Run the tests again