Jazz Forum Welcome to the Jazz Community Forum Connect and collaborate with IBM Engineering experts and users

RQM cannot invoke "cmd.exe" configured application in RFT, while running the script

 RQM cannot invoke "cmd.exe" configured application in RFT, while running the script?

RQM v4.0.1 and higher
RFT v8.2.1 and higher

An RFT script with the actions as below when executed from RFT eclipse UI, command line, RQM has the behavior given below..

script content...
startApp("cmd_prmt");
sleep(5);
// Window: cmd.exe: Administrator: C:\windows\system32\cmd.exe
administratorCWindowsSystem32C().click();
administratorCWindowsSystem32C().inputKeys("cd /{ENTER}");
administratorCWindowsSystem32C().inputKeys("cd Pro{TAB}");
administratorCWindowsSystem32C().inputKeys("{ENTER}");
administratorCWindowsSystem32C().inputKeys("dir{ENTER}");
administratorCWindowsSystem32C().inputKeys("exit{ENTER}");
behavior...

eclipse UI - works!
command line - works!
RQM UI - does not work {invokes script, fails to start application!! and hence fails}

command : (same as in RFT adapter console, works when invoked directly on RFT adapter machine)
"C:\IBM\RFT\jdk\jre\bin\java.exe" -Drqm.mode=true -Drqm.task="C:\Users\ADMINI~1\AppData\Local\Temp\RQMRFTTask3040109936879455416.xml" -jar "C:\IBM\RFT\FunctionalTester\bin\rational_ft.jar" -datastore "C:\RFTwork\TProject1" -rt.log_format xml  -iterationcount -1 -rt.bring_up_logviewer false  -execmode rqm  -playback cmdPrmt

Why is the "cmd.exe" invoke failing in RQM playback? issue not observed for other applications eg: calc.exe, browser, classicJava..

0 votes


Accepted answer

Permanent link
There is a technote addressing this issue.
http://www-01.ibm.com/support/docview.wss?uid=swg21585220  -Running an RFT Script From RQM results in the inability to open a command prompt window .

Thanks,
Deepa
Sunil Kumar R selected this answer as the correct answer

1 vote

Comments

 Thanks Deepa, that helps..

+ points from RFT perspective

RFT execution through adapter uses command line, so when a cmd is already open it requires additional code to invoke a new command line.

One can verify the same with the steps as below:-
a. Open a command prompt using "Start > Run > cmd".
b. Type "cmd" in the command prompt opened by a. : No action
c. Type "cmd.exe /k start cmd.exe" instead, and it opens a new command prompt.

When RFT script is invoked through RQM adapter similar situation is faced and hence additional code (as shown in the technote above) is needed to help invoke cmd promt.


2 other answers

Permanent link
Is there any error message on the console or log?

0 votes

Comments

Nope there are no errors.. 


Infact RFT script playback goes ahead without problems (even though the cmd is not opened by the playback)..

08:02:36:766 AM Starting Adapter
08:02:36:956 AM Login to https://clm.jkebanking.net:9443/qm   <Project Area: = JKE Banking (Quality Management)>
08:03:18:715 AM Execution request: C:\RFTwork\TProject1\cmdPrmt received
08:03:18:821 AM Executing RFT command "C:\IBM\RFT\jdk\jre\bin\java.exe"  -Drqm.mode=true -Drqm.task="C:\Users\ADMINI~1\AppData\Local\Temp\RQMRFTTask2662736152400760501.xml" -jar "C:\IBM\RFT\FunctionalTester\bin\rational_ft.jar" -datastore "C:\RFTwork\TProject1" -rt.log_format xml  -iterationcount -1 -rt.bring_up_logviewer false  -execmode rqm  -playback cmdPrmt
08:03:55:793 AM Execution of script cmdPrmt done
 


Permanent link
Hi Sunil,
This seems to be an issue with the RFT script. Looks like you may have to copy the referenced resources to the RFT customization folder. Normally this can be found at C:\ProgramData\IBM\RFT\customization folder however please confirm with RFT Team regarding this.
Thanks,
Deepa

0 votes

Comments

Deepa, I have tested with calc.exe as the AUT and this playback works fine through RQM web ui execution..


So the fault seems to be only when "cmd.exe"  is involved as an app..
Yes, I am aware of the customization folder but should the behavior be same for "calc.exe" as an app then?

Best Regards, Sunil

Your answer

Register or log in 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.

Search context
Follow this question

By Email: 

Once you sign in you will be able to subscribe for any updates here.

By RSS:

Answers
Answers and Comments
Question details

Question asked: Jun 12 '13, 10:36 a.m.

Question was seen: 7,761 times

Last updated: Jun 19 '13, 8:35 a.m.

Confirmation Cancel Confirm