Batch file 发出批处理文件以从命令promt运行visual studio测试

Batch file 发出批处理文件以从命令promt运行visual studio测试,batch-file,command-line,Batch File,Command Line,我正在尝试从批处理文件运行VisualStudio单元测试。下面是我写的代码 代码: 启动C:\Program Files x86\Microsoft Visual Studio 12.0\Common7\IDE\MSTest和MSTest/testcontainer:C:\Users\u1hc207\Desktop\Automation Testing- Boat\TFS\u Integrated\u Framework\TFS\u Integrated\u Framework\Automat

我正在尝试从批处理文件运行VisualStudio单元测试。下面是我写的代码

代码:

启动C:\Program Files x86\Microsoft Visual Studio 12.0\Common7\IDE\MSTest和MSTest/testcontainer:C:\Users\u1hc207\Desktop\Automation Testing- Boat\TFS\u Integrated\u Framework\TFS\u Integrated\u Framework\AutomationFrameworkExecution\bin\Debug\AutomationExecution.dll

但是,我发现MSTest不是commandpromt中可识别的命令


我想知道我做错了什么。

你不需要开始。所有包含空格的路径都需要双引号。您还需要删除&-您正在执行一条语句,而不是多条语句。它应该是C:\Program Files x86\Microsoft Visual Studio 12.0\Common7\IDE\MSTest\MSTest.exe/testcontainer:C:\rest of path\Debug\AutomationExecution.dlt谢谢!。。这解决了我的问题