I need the number of all defects in a testplan. One defect can be linked to multiple tests but should only count as one. How can I do that? I can't use the JQL "defectsCreatedDuringTesting()" since some defects have to be created outside of a test.
I have the same problem?
Do you were able to solve it?
Hi and sorry for the long wait.
I do it like this for each priority and in the ende I put the prior vars in a table. You get the total number of defects, and how many are in a given state.
Hope this helps.
${set(Prior1,0)}
${set(StatOpenPrio1,0)}
${set(StatClosedPrio1,0)}
${set(StatResPrio1,0)}
${set(StatInPPrio1,0)}
#{if (%{'${BulkIssueIndex}'==0})}
&{for issues|filter=%{'${IssueTypeName}'.equals('Product defect')}}
#{if (%{'${Priority}'.equals('1')})}
#{if (%{'${Status}'.equals('Open')})}
${set(Prior1,%{${Prior1}+1})}
${set(StatOpenPrio1,%{${StatOpenPrio1}+1})}
#{end}
#{if (%{'${Status}'.equals('Resolved')})}
${set(Prior1,%{${Prior1}+1})}
${set(StatResPrio1,%{${StatResPrio1}+1})}
#{end}
#{if (%{'${Status}'.equals('In Progress')})}
${set(Prior1,%{${Prior1}+1})}
${set(StatInPPrio1,%{${StatInPPrio1}+1})}
#{end}
#{if (%{'${Status}'.equals('Closed')})}
${set(Prior1,%{${Prior1}+1})}
${set(StatClosedPrio1,%{${StatClosedPrio1}+1})}
#{end}
#{end}
&{end}
#{end}
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Thanks for the reply.
I got this solution from the support, using js, hope it help someone else:
${set(Count,0)}
${set(repeatp, “A”)}
#{for tc=TestsCount}
#{for s=Tests[tc].LinksCount|filter=%{‘${Tests[tc].Links[s].IssueType}’.equals(‘Bug’)}}
${set(Count,%{${Count} + 1})}
#{end}
#{end}
#{if (%{‘${Count}‘.equals(‘0’)})}
This Release has no Defects
#{end}
#{if (%{!‘${Count}‘.equals(‘0’)})}
S. No. | Issue Key |
${set(Count,0)}
#{for tc=TestsCount}
#{for s=Tests[tc].LinksCount|filter=%{‘${Tests[tc].Links[s].IssueType}’.equals(‘Bug’)}}
#{if (%{“${repeatp}”.indexOf(“${Tests[tc].Links[s].Key}”)==-1})}
${set(Count,%{${Count} + 1})}
${Count} | @{title=${Tests[tc].Links[s].Key}|href=${BaseURL}/browse/${Tests[tc].Links[s].Key}} |
${set(repeatp,%{“${repeatp}”.concat(”${Tests[tc].Links[s].Key}”)})}
#{end}
#{end}
#{end}
#{end}
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Online forums and learning are now in one easy-to-use experience.
By continuing, you accept the updated Community Terms of Use and acknowledge the Privacy Policy. Your public name, photo, and achievements may be publicly visible and available in search engines.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.