It's all about the answers!

Ask a question

Cannot get correct test result by RQM command line adapter


Chao Wei (111) | asked Nov 25 '10, 6:07 a.m.
Hi,

I have successfully configured RQM command line adapter on my Windows test machine. I am able to run my test script in RQM by calling a batch file on that test machine. The test script can be executed successfully. The problem I have is that the progress bar always hangs somewhere in RQM and I can see a line like "Status: Calling comparer utility..." in both RQM and the start command line adapter window on my test machine. As a result, the test result is always unknown (a question mark) in RQM even if the test script execution is successful.

I am aware of the following RQM command line adapter configuration guide.

"Create a test job for your application-under-test. This job can be a batch file, a shell script or any executable that takes arguments and returns a status. A process exit code of 0 is a "Pass" status for test execution. Any other return code indicates a "Fail" test execution status."

This is the batch file I am using.

run.bat

@echo off
rem start BVT test script
staf local stax execute file {STAF/Env/Home}/testcase/itfimBVT_existingWAS_init.xml wait returnresult
exit /b 0

Can anybody shed a light on how to indeed make my batch file to return an exit code which is recognizable by RQM so that I can see the correct test result in RQM? Thanks.

One answer



permanent link
Kurtis Martin (1.4k11) | answered Nov 29 '10, 6:00 p.m.
JAZZ DEVELOPER
I'm not sure where "Status: Calling comparer utility..." is coming from. What version of RQM are you using? In either case the quote you have from the adapter configuration guide seems correct. In your case your batch script always returns 0 via "exit /b 0" so the result status will always be Pass. I see you call a separate staf command and I believe your run.bat waits for that command to return. If you want a status other than Pass, you would need to remove the hardcoded "exit /b 0" from run.bat and come up with a way for run.bat to return the status code returned from the staf command it invoked.

Your answer


Register or to post your answer.


Dashboards and work items are no longer publicly available, so some links may be invalid. We now provide similar information through other means. Learn more here.