4

tried specifying the location in the github actions for mstest "C:\Program Files (x86)\Microsoft Visual Studio\2019\Professional\Common7\IDE\MSTest.exe".

But it says cannot find path as it does not exist.

akay
  • 91
  • 1
  • 10

1 Answers1

3

Is you pipeline using the Setup Msbuild task?

Here is an example of pipeline to display MsTest's help:

name: Display MsTest helper

on:
  push:
    branches:
      - '**' 

jobs:
  build:
    runs-on: windows-latest

    steps:
      - name: setup-msbuild
        uses: microsoft/setup-msbuild@v1

      - name: Run a one-line script
        run:  '& "$(vswhere -property installationPath)\Common7\IDE\MSTest.exe" /help'
Lucas
  • 1,171
  • 9
  • 21
  • 1
    It's to invoke a command after resolving a variable name. You can read more here: https://stackoverflow.com/questions/22074507/what-does-the-symbol-in-powershell-mean – Lucas Nov 04 '20 at 22:55