It's all about the answers!

Ask a question

Question about changing test case template


Bob Wang (482119) | asked Nov 03 '11, 3:04 p.m.
I have created hundreds of manual test cases in a test plan. When I created them, I forgot to change the template, so the default template applied to all of those test cases. Now, when I open a test case, a lot of sections are showing up at the left side. I found the only way I can remove the sections is through "Manage Sections" where I can select the sections I need. However, it is very slow because I have many test cases to change. Is there a better way to do this job? I hope I can still apply another template after the test case is created.

2 answers



permanent link
Bob Wang (482119) | answered Nov 25 '11, 11:42 a.m.
I am trying to change the test case template by using REST API. What I did was GET the xml for a test case, and then modify the template from

<template href="https://ecdclm.ottawa.ibm.com:9445/qm/service/com.ibm.rqm.integration.service.IIntegrationService/resources/WebSphere+Commerce+%28Quality+Management%29/template/testcase/com.ibm.rqm.planning.templates.testcase.default"/>

to

<template href="https://ecdclm.ottawa.ibm.com:9445/qm/service/com.ibm.rqm.integration.service.IIntegrationService/resources/WebSphere+Commerce+%28Quality+Management%29/template/testcase/com.ibm.rqm.planning.templates.testcase.template_1315497079656"/>

And then PUT the xml file to that test case URL. From the standard output, I saw the operation was successful.

D:\>java -jar RQMUrlUtility.jar -command PUT -user bobwang@ca.ibm.com -password
xxxxxxx -filepath d:\\tc_93.xml -url https://ecdclm.ottawa.ibm.com:9445/qm/ser
vice/com.ibm.rqm.integration.service.IIntegrationService/resources/WebSphere+Com
merce+(Quality+Management)/testcase/urn:com.ibm.rqm:testcase:93
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
<<<<<----- ---->>>>>
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

RQMUrlUtility: Connected to https://ecdclm.ottawa.ibm.com:9445 using project "We
bSphere+Commerce+(Quality+Management)"
Nov 25, 2011 11:41:09 AM org.apache.commons.httpclient.HttpMethodDirector isRedi
rectNeeded
INFO: Redirect requested but followRedirects is disabled
RQMUrlUtility: Calling method to upload XML from a specified file t
o URL
RQMUrlUtility: Server Response code: 200
RQMUrlUtility: XML string from file : "d:\\tc_93.xml" written to URL
: "https://ecdclm.ottawa.ibm.com:9445/qm/service/com.ibm.rqm.integration.servic
e.IIntegrationService/resources/WebSphere+Commerce+(Quality+Management)/testcase
/urn:com.ibm.rqm:testcase:93 "

However, I found the template was not modified. I tried to use the same way to modify some other field such as test case name, description, and test script link, seems these operations are fine.

Could anyone take a look and let me know what is wrong? Or is this a defect?

permanent link
Paul Slauenwhite (8.4k12) | answered Nov 25 '11, 2:09 p.m.
FORUM MODERATOR / JAZZ DEVELOPER
Unfortunately, test planning resource templates are immutable using the RQM Reportable REST API meaning they cannot be changed once the test planning resource has been created. In addition, the OOTB templates are read-only. You will have to manually update the sections in the test planning resource editor -or- read/delete/recreate the test planning resources.

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.