[closed] How to update/modify multiple test cases in RQM using REST/OSLC?
The question has been closed for the following reason: "The question is answered, right answer was accepted" by davidhoney Jun 26 '23, 4:05 a.m.
Accepted answer
Hi Andrew,
The url and method is correct. The problem is with your body xml.
As the wiki stated that the body xml should be in format of
<?xml version="1.0" encoding="utf-8"?>
<feed xmlns="http://www.w3.org/2005/Atom">
<entry>
<id>resource ID</id>
<content>
resource XML
</content>
</entry>
</feed>
Something similar to
<?xml version="1.0" encoding="utf-8"?>
<feed xmlns="http://www.w3.org/2005/Atom">
<entry>
<id>https://<server_url>/qm/service/com.ibm.rqm.integration.service.IIntegrationService/resources/<project_name>/testcase/urn:com.ibm.rqm:testcase:2</id>
<content>
<ns19:testcase
xmlns:ns19="http://jazz.net/xmlns/alm/qm/v0.1/"
xmlns:ns3="http://purl.org/dc/elements/1.1/"
xmlns:ns21="http://www.w3.org/1999/XSL/Transform">
<ns3:title type="text">Test updated</ns3:title>
<ns19:weight>500</ns19:weight>
</ns19:testcase>
</content>
</entry>
<entry>
<id>https://<server_url>/qm/service/com.ibm.rqm.integration.service.IIntegrationService/resources/<project_name>/testcase/urn:com.ibm.rqm:testcase:20</id>
<content>
<ns19:testcase
xmlns:ns19="http://jazz.net/xmlns/alm/qm/v0.1/"
xmlns:ns2="http://schema.ibm.com/vega/2008/"
xmlns:ns3="http://purl.org/dc/elements/1.1/"
xmlns:ns21="http://www.w3.org/1999/XSL/Transform">
<ns3:title type="text">Test updated 1</ns3:title>
<ns19:weight>1000</ns19:weight>
</ns19:testcase>
</content>
</entry>
</feed>
Add the proper xmlns for the tags you would like to update i.e. ns3 for updating creator under <ns3:creator>.
You should also add the proper headers. Please go through the wiki for more clarification.
Thanks,
Monika Rajput
Comments
2 other answers
Hi user PUT method with URL: https://<serverUrl>/qm/service/com.ibm.rqm.integration.service.IIntegrationService/resources/JKE%20Banking%20(Quality%20Management)/testcase/
and below is the xml file:
<?xml version="1.0" encoding="UTF-8"?>
<feed xmlns="http://www.w3.org/2005/Atom">
<title type="text">testcase ATOM feed for project area JKE Banking (Quality Management)</title>
<link href="https://d-9376:9443/qm/web/console/" rel="alternate" />
<link rel="self" href="https://d-9376:9443/qm/service/com.ibm.rqm.integration.service.IIntegrationService/resources/JKE+Banking+%28Quality+Management%29/testcase" />
<entry>
<updated>2020-06-30T15:13:56.679Z</updated>
<title type="text">Test - Donors Deposit Money Into a Pooled Assistance Fund</title>
<summary type="text" />
<link href="https://d-9376:9443/qm/service/com.ibm.rqm.integration.service.IIntegrationService/resources/JKE+Banking+%28Quality+Management%29/testcase/urn:com.ibm.rqm:testcase:2" rel="alternate" type="application/xml" title="" />
<link href="https://d-9376:9443/qm/web/console/JKE%20Banking%20%28Quality%20Management%29/_KiNAcLriEeqJ-v35v4TKwA#action=com.ibm.rqm.planning.home.actionDispatcher&subAction=viewTestCase&id=2" rel="enclosure" type="text/html" title="Web Console" />
</entry>
</feed>
It returns 302 response code but test cases is not updated.
Please suggest if i miss something
Hi Andrew,
The bulk upload is supported on POST requests only. Please see jazz.net wiki Bulk Upload for more information.
Thanks,
Monika Rajput
Comments
Binoy Udayan
Jun 26 '23, 4:03 a.m.David Honey
FORUM ADMINISTRATOR / FORUM MODERATOR / JAZZ DEVELOPER Jun 26 '23, 5:01 a.m.