🖋️
QualityMate
  • QualityMate
  • Getting Started
    • Introduction
    • Why QualityMate
    • Architecture
    • Supported Web Browsers
    • Glossary
  • Components
    • UI Player
      • Basic Concepts
      • UiPlayer
      • MSTest Integration
      • Samples
        • QualityMate Sample Desktop
        • QualityMate Sample Web
        • QualityMate MSTest Integration Sample Desktop
        • QualityMate MSTest Integration Sample Web
        • QualityMate Integration with Test Frameworks
        • Web Authentication Sample
      • QualityMate Project Template
    • UI Recorder
      • Basic Concepts
      • Setting Up the Recorder
      • Validating an Element
      • Generating QualityMate Solution
  • Tools
    • File Comparators
    • Image Processor
    • Project Merger
    • Test Case Generator
      • Filters
      • Rename Recorded Controls
  • Basic Concepts
    • Page Object
      • Work Guide
    • Controls
      • Control Types
        • Generic Types
        • Desktop types
        • Web Types
        • WebMap types
          • Kendo PowerBuilder
          • Kendo WinForms
          • Kendo Silverlight
      • Interactions
        • SendKeys
        • Validate
    • Selectors
      • Selectors in Code
      • Default Selector
      • Shared Selector
      • Selectors Category
        • CSS Selector
        • XPath Selector
        • Image Selector
        • Frame Selector
      • Identifying Selector
        • Identify for Windows Desktop
        • Identify for Web
  • How to Guides
    • Setting Up the Configuration
      • Parameters
      • Context
      • Loading External Data
    • Awaiting for the Application
      • Busy Loaders
      • Retries
    • Defining Controls
      • Extending Controls
      • Control Slice
      • Control Collection
    • Logging on Tests
      • QualityMate Reports
      • Logging
  • Help
    • Best Practices
      • Environment
      • Tests
      • Page Objects
      • Validations
      • Interactions
      • Image Comparisons
    • Known Issues
    • Continuous Integration
      • Agents Session
    • Upgrading QualityMate
      • From version 7 to version 8
      • Previous Versions
      • How to switch from TestFeature to UiTest
    • VS Test
      • Command Line
      • Generate Reports
  • API
    • Control Interfaces
      • IButton
      • ICheckBox
      • IComboBox
      • IControl
      • IControlSlice
      • IDateTimePicker
      • IElement
      • IGrid
      • IGroupBox
      • ILabel
      • IListBox
      • IMenu
      • INumericUpDown
      • IPageObject
      • IProgressBar
      • IRadioButton
      • IRadioButtonGroup
      • ISplitButton
      • IStatusStrip
      • ITab
      • ITextBox
      • IToggleButton
      • IToolBar
      • ITreeView
    • Behavior
      • ICheckableControl
      • IList
      • ITextControl
    • Enums
      • ClickType
      • KeyModifiers
      • MouseButton
  • Changelog
    • Changelog
      • Version 8
      • Version 7
      • Version 6
      • Version 5
      • Version 4
      • Version 3
Powered by GitBook
On this page
  • Using VSTest from a visual studio installation
  • Using VSTest from the TestPlatform package
  • Examples

Was this helpful?

  1. Help
  2. VS Test

Command Line

Run tests in the command line

PreviousVS TestNextGenerate Reports

Last updated 4 years ago

Was this helpful?

The vstest.console.exe is the command-line tool used by Visual Studio to run tests.

Using VSTest from a visual studio installation

Open a Developer Command Prompt, or you can find the vstest.console.exe in the Visual Studio installation folder, commonly found at:

%Program Files (x86)%\Microsoft Visual Studio\<version>\<edition>\Common7\IDE\CommonExtensions\Microsoft\TestWindow

Using VSTest from the TestPlatform package

Download the latest TestPlatform package from the and decompress it, you will find the vstest.console.exe at Tools\net451\Common7\IDE\Extensions\TestPlatform

This method can be useful to distribute a test Assembly with VSTest, which can test cases or reproduce issues on different machines without requiring a Visual Studio installation. The next layout shows the structure of a distributable folder.

📦MyDistributableFolder
 ┣ 📂TestPlatform
 ┃  ┣ 📂Common7
 ┃  ┗ 📂Team Tools
 ┗ 📂Test
    ┗ 📜myProject.Test.dll

Examples

To run the tests that use QualityMate that uses a .runsettingsfile, you will need to append the option /Settings:[FilePath]. to the VSTest executable, for example:

vstest.console.exe path\to\myProject.Test.dll /Settings:path\to\mySettings.runsettings

Multiple Assemblies can be used with the command below:

vstest.console.exe path\to\myProject.Test.dll path\to\otherProject.Test.dll /Settings:path\to\mySettings.runsettings

Filters can be used specify which test cases are going to run based on its traits such as [Priority] using the command:

vstest.console.exe path\to\myProject.Test.dll /Settings:path\to\mySettings.runsettings /TestCaseFilter:"Priority=1"

For more information about the VSTest commands, you can find Microsoft's documentation about the vstest.console.exe options .

Microsoft NuGet site
here