How to create a Batch File for Visual Studio Command Prompt

后端 未结 7 791
既然无缘
既然无缘 2020-12-02 22:29

I want to create a batch file for Visual Studio 2008 x64 Cross Tools Command Prompt to do something continuesly in my PC, here is the senario.<

相关标签:
7条回答
  • 2020-12-02 22:59

    Try below batch file to run the MS test/Nunit test for C# tests.

    @echo off
    echo Run the CMD(Command Prompt) Program.
    echo.
    pause
    cls
    echo Target Framwork
    CD C:\Windows\Microsoft.NET\Framework64\v4.0.30319
    echo 'Project Path'
    msbuild  "C:\Git\ElementsCloud.Tests\Source\ElementsCloud.Tests.sln"/p:configuration=debug
    pause
    echo 'Project Dll path' and Execute tests
    cd C:\Program Files (x86)\Microsoft Visual Studio\2017\Professional\Common7\IDE\CommonExtensions\Microsoft\TestWindow
    vstest.console.exe "C:\Git\ElementsCloud.Tests\Source\Selenium.Tests\bin\Debug\net471\Selenium.Tests.dll" /Tests:Test1,Test2,Test3
    echo. 
    PAUSE
    EXIT
    
    0 讨论(0)
提交回复
热议问题