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

Populate the 'iteration' field of a TER through the API

I am attempting to populate the 'iteration' field of a TER through the API.  Can someone tell me how this would be done?

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

0 votes



2 answers

Permanent link
 Hi Matthew,
you can refer to the https://jazz.net/wiki/bin/view/Main/RqmApi
and do a GET request to the specific TER and the testphase url would contain in <testphase> section of the returned xml content such as


0 votes

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,

sorry for the misunderstanding, based on your last comment, I'm a little confused about your problem.
do you mean you want to get the testphase through REST API? if so my answer would resolve your problem.
if not, my guess is that you want to get the testphase url according to the name of the testphase? but my understanding is that if you are using RQM REST API why not get the url directly through the content of the TER?
my further guessing is that you want to get the url through the web ui, but web ui only contains the title, if you testphase is under one testplan and you could find testplan info in TER web ui and go to testplan then you can find the related testphase.
by the way, testphase defined could be found in https://bxv1v603.cn.ibm.com:9443/qm/admin#action=com.ibm.team.process.editProjectArea&itemId=_IbtcIOk9EeKmmPqwISE6Ag
and the "Timelines" section

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


Permanent link
Hi 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>

0 votes

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
× 10,938

Question asked: Jul 09 '13, 5:13 p.m.

Question was seen: 5,131 times

Last updated: Jul 26 '13, 6:23 a.m.

Confirmation Cancel Confirm