Search code examples
batch-filetfscoded-ui-testsmicrosoft-test-managermtm

Pass parameter to testsettings setup script


I am using MTM to run Tests using a specific "Test Settings".

I added a Setup script which is a batch file and its working fine. The batch file is

echo %1 %2

Now I am not able to figure out how to pass argument to this batch file.

I tried all the below methods, but the test run throws illigal character in path, incorrect file format, etc. errors.

C:\SetupScript.bat Hello World
"C:\SetupScript.bat" Hello World
"C:\SetupScript.bat" "Hello" "World"
start "" "C:\SetupScript.bat" Hello World

I am not able to figure out how to pass arguments to my batch file in Setup script. Please help.


Solution

  • I was also trying the same stuff, but it seems this is no currently possible through MTM. I am using MTM 2012.