• --Blame
Runs the tests in blame mode. This option is helpful in isolating the problematic tests causing test
host to crash. It creates an output file in the current directory as Sequence.xml that captures the
order of tests execution before the crash.
• --Diag<PATH_TO_LOG_FILE>
Enables verbose logs for the test platform. Logs are written to the provided file.
• --Framework<FRAMEWORK>
Target .NET Framework version used for test execution. Examples of valid values are .NETFramework,Ver‐sion=v4.6 or .NETCoreApp,Version=v1.0. Other supported values are Framework40, Framework45, Framework‐Core10, and FrameworkUap10.
• --InIsolation
Runs the tests in an isolated process. This makes vstest.console.exe process less likely to be stopped
on an error in the tests, but tests may run slower.
• -lt|--ListTests<FILE_NAME>
Lists all discovered tests from the given test container.
• --logger<LOGGER_URI/FRIENDLY_NAME>
Specify a logger for test results.
• To publish test results to Team Foundation Server, use the TfsPublisher logger provider:
/logger:TfsPublisher;
Collection=<team project collection url>;
BuildName=<build name>;
TeamProject=<team project name>
[;Platform=<Defaults to "Any CPU">]
[;Flavor=<Defaults to "Debug">]
[;RunTitle=<title>]
• To log results to a Visual Studio Test Results File (TRX), use the trx logger provider. This switch
creates a file in the test results directory with given log file name. If LogFileName isn’t provid‐
ed, a unique file name is created to hold the test results.
/logger:trx [;LogFileName=<Defaults to unique file name>]
• --Parallel
Run tests in parallel. By default, all available cores on the machine are available for use. Specify
an explicit number of cores by setting the MaxCpuCount property under the RunConfiguration node in the
runsettings file.
• --ParentProcessId<PROCESS_ID>
Process ID of the parent process responsible for launching the current process.
• --Platform<PLATFORM_TYPE>
Target platform architecture used for test execution. Valid values are x86, x64, and ARM.
• --Port<PORT>
Specifies the port for the socket connection and receiving the event messages.
• --ResultsDirectory:<PATH>
Test results directory will be created in specified path if not exists.
• --Settings<SETTINGS_FILE>
Settings to use when running tests.
• --TestAdapterPath<PATH>
Use custom test adapters from a given path (if any) in the test run.
• --TestCaseFilter<EXPRESSION>
Run tests that match the given expression. <EXPRESSION> is of the format <property>Operator<val‐ue>[|&<EXPRESSION>], where Operator is one of =, !=, or ~. Operator ~ has `contains' semantics and is
applicable for string properties like DisplayName. Parentheses () are used to group subexpressions.
For more information, see TestCase filter (https://github.com/Microsoft/vstest-docs/blob/main/docs/fil‐
ter.md).
• --Tests<TEST_NAMES>
Run tests with names that match the provided values. Separate multiple values with commas.
• -?|--Help
Prints out a short help for the command.
• @<file>
Reads response file for more options.
• args
Specifies extra arguments to pass to the adapter. Arguments are specified as name-value pairs of the
form <n>=<v>, where <n> is the argument name and <v> is the argument value. Use a space to separate
multiple arguments.