JQL - Select all Test tickets from All Test Sets associated with an User Story

Alexandre Fernandes April 26, 2019

Hi everyone,

In my project we usually have an User story ticket that is tested by one or more Test Sets, and each Test set has a set of Test tickets added.

I'm trying to query all the Test Cases from an user story but I could not do that...

In Summary, I need to collect all the Test Tickets from All Test Sets linked in the User Story...

 

First attempt:

Query in the user story, the list of Test Coverage

testcoverage.pngdd

looks like it is not possible, this information appears whenever a Test set with test cases is linked to the User Story, but I did not find a way to query this Test Coverage....

 

Second attempt:

query all the Test Sets linked with and user story and then query all the Test Cases linked with each Test Set.

I can find all the Test Sets from an User Story using, for instance, this jql:

issueFunction in linkedIssuesOf("key=USER_STORY_TICKET_ID") AND issuetype = "Test Set"

But I don't know how could I get this list of Test Sets and collect all Test tickets associated with them...

For a single Test Set, it's easy, I can use, for instance, this: 

issue in testSetTests("TEST_SET_TICKET_ID") 

but how could I do it for all the list of Test Sets?

 

Best Regards,

 

2 answers

1 accepted

0 votes
Answer accepted
Alexandre Fernandes April 30, 2019

in order to close this question, the query bellow is doing what I need

 

issuetype = 'Test' and key in requirementTests('USER_STORY_TICKET')

0 votes
Tarun Sapra
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
April 26, 2019

Hello @Alexandre Fernandes 

Did you try nesting the queries?

Based on your requirement 

But I don't know how could I get this list of Test Sets and collect all Test tickets associated with them...

issue in testSetTests("issueFunction in linkedIssuesOf('type=story') AND issuetype = 'Test Set'") 
Alexandre Fernandes April 26, 2019

Hi @Tarun Sapra , I tried to do that without success. I'm not used to create JQL too, but the problem in my case would be get all the TestSet ids from the first query and put in the second to retrieve the Test Cases

Tarun Sapra
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
April 26, 2019

Since it's tested query thus it shoudl work automatically and return you all the tests related to the test-set that are linked to any story.

Alexandre Fernandes April 29, 2019

Hi @Tarun Sapra  when I try to run this, it doesn't work, even when I scape the ".

for instace, supposing that we have the User Story ticket TICKET_1 linked to the test set ticket TICKET_2 that is linked with the Test Cases TICKET_3 AND TICKET_4.

how would be a valid query ?

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events