Populate the 'iteration' field of a TER through the API
I am assuming that I use the 'testphase' element, but don't know how to look up the href for a specific testphase. What are the inputs to drill down on a specific testphase href?
Can you provide me some direction? I have experimented a while with the RQMUrlUtility to prototype some solution, but I seem to be spinning on it.
In the end I need a way for the user to provide my program readable input to populate the TER iteration field though the API.
Thanks for your help.
Matt
2 answers
Comments
Hao Wan,
With respect, this answer only distantly relates to my question... :) I have spent hours with the RQM API wiki and am familiar with the cheat-sheet.
What I needed is the process by which I can populate a TER testphase given the human readable title. I don't know how to look up the testphase href based on the title. It's possible that there are other keys that are required for this drill down - I need your direction here.
Can you help?
Thanks.
Matt
Hi Mat,
Hao Wan,
My process requires human input of testphase title. Example "Iteration1".
My process will then use the RQM API to create a TER.
My process does not know how to publish the test phase to the TER given the title.
I hope this is clearer.
Thanks.
Matt
Here are the steps you need to following:
1) Get the specific test phase identifier (URL):
GET https://<host>:<port>/<context root>/service/com.ibm.rqm.integration.service.IIntegrationService/resources/<project area alias>/testphase/?fields=feed/entry/content/testphase[title='<test phase title>']/identifier
2) Create the TCER with
POST https://<host>:<port>/<context root>/service/com.ibm.rqm.integration.service.IIntegrationService/resources/<project area alias>/executionworkitem
-or-
PUT https://<host>:<port>/<context root>/service/com.ibm.rqm.integration.service.IIntegrationService/resources/<project area alias>/executionworkitem/<external ID>
Content:
<ns2:executionworkitem xmlns:ns2="http://jazz.net/xmlns/alm/qm/v0.1/" xmlns:ns1="http://schema.ibm.com/vega/2008/" xmlns:ns3="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:ns4="http://purl.org/dc/elements/1.1/" xmlns:ns5="http://jazz.net/xmlns/prod/jazz/process/0.6/" xmlns:ns6="http://jazz.net/xmlns/alm/v0.1/" xmlns:ns7="http://purl.org/dc/terms/" xmlns:ns8="http://jazz.net/xmlns/alm/qm/v0.1/tsl/v0.1/" xmlns:ns9="http://jazz.net/xmlns/alm/qm/v0.1/testscript/v0.1/" xmlns:ns10="http://jazz.net/xmlns/alm/qm/qmadapter/task/v0.1" xmlns:ns11="http://jazz.net/xmlns/alm/qm/qmadapter/v0.1" xmlns:ns12="http://jazz.net/xmlns/alm/qm/v0.1/executionworkitem/v0.1" xmlns:ns13="http://jazz.net/xmlns/alm/qm/v0.1/executionresult/v0.1" xmlns:ns14="http://jazz.net/xmlns/alm/qm/v0.1/catalog/v0.1" xmlns:ns16="http://jazz.net/xmlns/alm/qm/styleinfo/v0.1/" xmlns:ns17="http://www.w3.org/1999/XSL/Transform">
...
<ns2:testphase href="test phase identifier property"/>
...
</ns2:executionworkitem>