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

RQM: Need to download all attachments related to a Test Case Result

When I export Test Case Results, I get PDF files that display the link to the attachment link.  When I paste that attachment link into the browser, the attachment will automatically download.

I'd like to use a similar API call in the browser, passing the Test Case Result ID and get either the list of attachments ID's associated with that Test Case Result to then pop into the browser and download, or a call that will download all the attachments into the browser that are related to that Test Case Result.

I can use <server>/qm/service/com.ibm.rqm.integration.service.IIntegrationService/resources/<PA name>/executionresult/urn:com.ibm.rqm:executionresult:517 and it will display the correct TC result, but using flags like ?fields=executionresult/attachment do not get me the list of attachments or attachment.  I've tried to do this in Poster but not getting useful information.

Thanks

0 votes

Comments

When the first URL displays "the correct TC result", do you see the link to the attachment? If so, what does it look like?

The browser redirects to the GUI page and displays the Test Result with the Test Script steps and Actual Results.  Each of these Actual Results / Steps we'll have 1 to many attachments (screenshots).  


The new URL is:<Server name>/qm/web/console/<PA Name>#action=com.ibm.rqm.planning.home.actionDispatcher&subAction=viewResult&resultItemId=<_23Qy...etc>


Accepted answer

Permanent link
The xml path for attachments is
/feed/entry/content/executionresult/stepResults/stepResult/stepAttachment
However, according to the API doc (https://jazz.net/wiki/bin/view/Main/RqmApi#SupportedFieldsResources) you can only select as deep as stepResults with the fields parameter.  Also note that filtering by id is not supported for the executionresult object when using the fields parameter.  The best I think you could do is a query like this, using the title of the execution result to filter:

https://<server>/qm/service/com.ibm.rqm.integration.service.IIntegrationService/resources/<PA Name>/executionresult?strictFields=true&fields=feed/entry/content/executionresult[title='Donors will receive confirmation and receipt_Firefox_DB2_WAS_Windows']/stepResults
w h selected this answer as the correct answer

1 vote

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,951

Question asked: Aug 27 '15, 3:31 p.m.

Question was seen: 3,992 times

Last updated: Sep 01 '15, 11:56 a.m.

Confirmation Cancel Confirm