Questions tagged [vstest.console.exe]
102 questions
2
votes
1 answer
How to run mstest with VSTEST.CONSOLE.EXE in powershell
After reading and experimenting available posts in Stack overflow I am asking this question.
I'm struggling to trigger MSTEST in powershell
Here is my attempt (obviously with the help of posts available in stack overflow)
$testDLL =…

user790049
- 1,154
- 1
- 9
- 21
2
votes
1 answer
Using vstest.console.exe, how do I get the fully qualified names of all the test methods of an assembly?
The /ListTests option only outputs the methods name without their class and namespaces, this doesn't make any sense! And the documentation doesn't seem to provide any additional tools to do this.

TommyD
- 731
- 8
- 14
2
votes
0 answers
Not working with vstest.console.exe when .runsettings file is specified - MS Test
I am using MSTest project to automate my system. The test project work fine. But I need to run the test project in my production with out installing visual studio.
So that I am using VSTest.Console.exe command-line.
My Login method as below
…

Krishan
- 169
- 2
- 12
2
votes
1 answer
VSTS+ SonarQube + DotNetCore 2.0 + Unit Tests
Anyone know the right combination of VS Tasks, arguments and commandlines to get these 4 things to play nice together?
I can get SonarQube to do analysis on the code doing the following:
SonarQube Scanner for MSBuild - Begin Analysis
Visual Studio…

Josh Handel
- 1,690
- 2
- 13
- 21
2
votes
1 answer
vstest.console.exe ListTests with FullyQualifiedName
/ListTests option of vstest is returning a list of test method names inside a dll.
Is there a way to return a list of FullyQualifiedNames?
So instead of getting TestMethodName I would like to receive NamespaceName.ClassName.TestMethodName.

Cirate
- 151
- 1
- 8
2
votes
0 answers
TeamCity can not start MSTest.exe or vstest.console.exe
I am getting this error when I try to run unit tests via teamcity
MyTeamCity version is 9.1 and I am using Visual Studio 2015.
If I change the name of MSTest.exe or vstest.console.exe it throws another error about finding the files. Also I think…

MSK
- 1,035
- 1
- 10
- 19
1
vote
0 answers
How do i solve vstest error "The test source file "C:\Windows\MyTestProject.dll" provided was not found
echo Setting path
SET PATH=%PATH%;D:\My-Tests-Folder\TestPlatform\tools\net462\Common7\IDE\Extensions\TestPlatform
cd "D:\My-Tests-Folder\MSTest"
start cmd /k vstest.console.exe MyTestProject.dll /testcasefilter:TestCategory=Category123
I have the…

StackTrace
- 9,190
- 36
- 114
- 202
1
vote
1 answer
Debug vstest adapter
I'd like to debug my own vstest Adapter.
I'm working on integrating of my own test framework/case into VS 2022. Currently, my adapter work on Test Explorer that I can see my dummy case on it. But, I don't know how to debug into the code of…

ever
- 63
- 6
1
vote
0 answers
Github Action calling vstest x86 fails with 'transport connection' error
We use Github Actions to build and test our ActiveX control. We started a few weeks ago and made a lot of progress. We build and test for x86 and x64 using a matrix.
Starting a week ago the two build still succeed and the x64 unit test succeeded but…

Paul Meems
- 3,002
- 4
- 35
- 66
1
vote
1 answer
vstest.console.exe error: Unable to read data from the transport connection: An existing connection was forcibly closed by the remote host
I have ran my test project from Test Explorer in Visual Studio 2022 and fortunately all tests passed. On the other side I'm trying to use vstest.console.exe to run MyProject.Tests.build.appxrecipe file but it's failing.
The log is the following:
The…

rlm96
- 193
- 1
- 15
1
vote
0 answers
How can I run 'dotnet test' on a solution file with both UWP and .NET Core / .NET 6 test projects?
I have a solution that contains several .NET Standard, .NET Core, .NET 6, and finally UWP projects in it.
Additionally, I have test projects for everything, including the UWP projects.
My problem is, is that I cannot run the dotnet test, or even the…

Aron
- 372
- 5
- 18
1
vote
0 answers
Why is Visual Studio Test Task Is Not Able to Create Code Coverage In Azure DevOps?
I am using Azure DevOps 2020 with self hosted agents. Using this I have created a pipeline for executing asp.net unit test cases using VS test task and have also selected enable code coverage option.
The test cases are getting executed successfully…

SRP
- 999
- 4
- 21
- 39
1
vote
0 answers
Why does the Custom Attribute decrease the speed of test discovery in MSTest?
I have defined a new class name MyTestMethodAttribute and it is been inherited from TestMethod I have changed nothing in this custom attribute other than overriding the Execute Method:
[AttributeUsage(AttributeTargets.Method)]
public class…

Ravaei
- 8
- 6
1
vote
0 answers
vstest.console.exe does not return any exit code
Problem: I'm running vstest.console, but it is not showing any exit code. below is the command that I'm running.
"C:\Program Files (x86)\Microsoft Visual Studio\2019\Professional\Common7\IDE\CommonExtensions\Microsoft\TestWindow\vstest.console"…

Dee
- 11
- 1
1
vote
2 answers
VSTest: Order the execution of test assemblies
Our codebase has more than 100 projects with tests in each. Some test assemblies take more time while some other assemblies are taking less time for the execution of the tests.
The Azure DevOps Server is running our whole test suit in parallel,…

F. Baum
- 301
- 1
- 5
- 17