I have a batch script (.bat file) that I run from commandline to execute my test scripts. Now I would like to invoke this batch script from HP Quality Center. How should I run a batch script from Quality Center?
Asked
Active
Viewed 2,738 times
1 Answers
1
You can create a VAPI-XP test in Quality Center and start your batch script from the Test Script of the test case using some code like this (VBScript):
mycommand = "C:\tmp\some.bat"
TDOutput.Print "Starting " & mycommand
result=run(mycommand,0,true)
TDOutput.Print "Test ended with " & result

Roland
- 1,220
- 1
- 14
- 29
-
Hi Roland, I am experimenting the same, but not able to get the desired outcome. I have created a test using selenium and TestNG in Java and make an executable jar, I am running the jar local machine using batch script.Up to this part is works fine, but when I try to use you code snippet to run in HP ALM, my test is passed but in real my test is not running locally Am I missing anything? thanks – user790049 Jun 30 '16 at 02:09