All eazyBI for Jira eazyBI for Confluence Private eazyBI

Xray Requirement coverage
eazyBI for Jira

The following report examples are based on Xray Test Management integration. 

Xray Requirement coverage report represents an overview of the requirement's current status, its coverage by tests and executions and reported defects.


This report has Xray Requirement dimensions on rows and pages to filter report data by requirement issue Project, Epic, or Parent issue. On rows select the Requirement level.

In columns, there are many measures describing each requirement.

  • Xray Requirement status is a calculated measure that gets issue property value from Issue status for each requirement. You can show the issue status using the expression below:

    -- annotations.group=Xray User defined
    [Status].[Status].getMemberNameByKey(
      [Xray Requirement].CurrentHierarchyMember.get('Status ID')
    )

    Or you can choose more generalized information and show the category of status (To Do, In Progress, Done)

    -- annotations.group=Xray User defined
    CASE WHEN NOT IsEmpty(  [Xray Requirement].CurrentHierarchyMember.get('Status ID'))
    THEN
      [Status.Category].[Status].GetMemberByKey(
        [Xray Requirement].CurrentHierarchyMember.get('Status ID')
      ).Parent.Name
    END


    Apply the conditional cell formatting to color-code statuses and make the report more readable. Choose the option Exact value and assign a color for each status.

  • Xray Tests created is a default eazyBI measure for Xray and represents how many test cases are created to cover each requirement.
  • Xray Tests with executions is a default eazyBI measure for Xray and represents how many test cases are executed, executing or scheduled for execution. As each test case is counted once in this measure (regardless of the number of executions), if this number is less than Xray Tests created, it means that some of requirement tests are not executed or scheduled for the execution yet.
  • Xray Test Runs is a default eazyBI measure for Xray that represents the number of times requirement tests (issue type "Tests") have been executed, in execution, or scheduled for execution.
    Click on the measure and choose to Drill into → Xray → Xray Test Run Status → Status to split test runs by their results.
    Again, You can apply the conditional cell formatting for each execution status to color-code and highlight columns with values. Choose the option Range.
  • Xray Tests defect count is a default eazyBI measure for Xray and represents how much unique defects are found during the testing of the requirement (test defects are related to test executions).
  • Xray Defect list is a calculated measure and provides a bit more information on the defects counted in previous column: defect key and its status.
    The link to the defect is clickable, so you can open issues directly in Jira. Update the code YOUR_JIRA_DOMAIN to specify the path (URL) to your Jira domain. And set measure formatting to Markdown to represent links correctly.
    -- annotations.group=Xray User defined
    Generate(
      --filter set of unresolved defects
      Filter(
        Descendants([Xray Defect].CurrentMember, [Xray Defect].[Defect]),
        [Measures].[Xray Tests defect count] > 0
      ),
      --generate a list of clicable defect keys
      '[' ||
      [Xray Defect].CurrentHierarchyMember.Name ||
      ']' ||
      --update the YOUR_JIRA_DOMAIN with right URL for you
      '(http://YOUR_JIRA_DOMAIN/browse/' ||
      [Xray Defect].CurrentHierarchyMember.Name || 
      ') ' || 
      [Measures].[Xray Defect status],
      ', '
    )
    
    --set measure Formatting to Text -> Markdown

Copy and import report definition into your eazyBI account to get this report together with all calculated measures:

Report definition
{
  "cube_name": "Issues",
  "cube_reports": [ {
     "name": "Xray Requirement coverage",
     "result_view": "table",
     "definition": {"columns":{"dimensions":[{"name":"Measures","selected_set":["[Measures].[Xray Requirement Status]","[Measures].[Xray Tests created]","[Measures].[Xray Tests with executions]","[Measures].[Xray Test Runs]","[Measures].[Xray Tests defect count]","[Measures].[Xray Defect list]"],"members":[{"depth":0,"name":"Xray Test Runs","full_name":"[Measures].[Xray Test Runs]","format_string":"#,##0","annotations":{"group":"Xray","drill_through_dimension_levels":"[Xray Test].[Test], [Xray Test Execution].[Execution]","drill_through_by":"xray_test_execution","predefined":"true"},"drilled_into_dimension":"Xray Test Run Status"}]},{"name":"Xray Test Run Status","selected_set":["[Xray Test Run Status].[Status].Members"],"members":[],"bookmarked_members":[]}]},"rows":{"dimensions":[{"name":"Xray Requirement","selected_set":["[Xray Requirement].[All Xray Requirements]"],"selected_set_expression":"DescendantsSet({{selected_set}}, [Xray Requirement].[Requirement])","members":[],"bookmarked_members":[]}],"nonempty_crossjoin":false},"pages":{"dimensions":[{"name":"Xray Requirement","duplicate":true,"selected_set":["[Xray Requirement].[All Xray Requirements]"],"members":[{"depth":0,"name":"All Xray Requirements","full_name":"[Xray Requirement].[All Xray Requirements]","drillable":true,"type":"all","expanded":true,"drilled_into":false}],"bookmarked_members":[],"current_page_members":["[Xray Requirement].[All Xray Requirements]"]},{"name":"Xray Test Plan","selected_set":["[Xray Test Plan].[All Xray Test Plans]"],"members":[{"depth":0,"name":"All Xray Test Plans","full_name":"[Xray Test Plan].[All Xray Test Plans]","drillable":true,"type":"all","expanded":true,"drilled_into":false},{"depth":1,"name":"Xray Space Dog","full_name":"[Xray Test Plan].[Xray Space Dog]","drillable":true,"key":"XDOG","expanded":true,"drilled_into":false,"parent_full_name":"[Xray Test Plan].[All Xray Test Plans]"}],"bookmarked_members":[],"current_page_members":["[Xray Test Plan].[All Xray Test Plans]"]}]},"options":{},"view":{"current":"table","maximized":false,"table":{"row_dimension_headers":{"Xray Requirement":true},"cell_formatting":{"[Measures].[Xray Requirement Status]":{"type":"exact_value","rules":[{"exact_value":"Done","text_color":"#00875A","bold":true},{"exact_value":"In Progress","text_color":"#FFBC29","bold":true},{"exact_value":"To Do","text_color":"#2F579C","bold":true}]},"[Xray Test Run Status].[PASSED]":{"type":"range","rules":[{"min":"1","background_color":"#86DBA6"}]},"[Xray Test Run Status].[TO DO]":{"type":"range","rules":[{"min":"1","background_color":"#EBECF0"}]},"[Xray Test Run Status].[EXECUTING]":{"type":"range","rules":[{"min":"1","background_color":"#FFF2A4"}]},"[Xray Test Run Status].[FAILED]":{"type":"range","rules":[{"background_color":"#FA80A7","min":"1"}]}}}},"calculated_members":[]}
  } ],
  "calculated_members": [{"dimension":"Measures","name":"Xray Defect status","format_string":"","formula":"[Status].[Status].getMemberNameByKey(\n  [Xray Defect].CurrentHierarchyMember.get('Status ID')\n)"},{"name":"Xray Requirement Status","dimension":"Measures","formula":"-- annotations.group=Xray User defined\nCASE WHEN NOT IsEmpty(  [Xray Requirement].CurrentHierarchyMember.get('Status ID'))\nTHEN\n  [Status.Category].[Status].GetMemberByKey(\n    [Xray Requirement].CurrentHierarchyMember.get('Status ID')\n  ).Parent.Name\nEND","format_string":""},{"name":"Xray Defect list","dimension":"Measures","formula":"-- annotations.group=Xray User defined\nGenerate(\n  --filter set of unresolved defects\n  Filter(\n    Descendants([Xray Defect].CurrentMember, [Xray Defect].[Defect]),\n    [Measures].[Xray Tests defect count] \u003e 0\n  ),\n  --generate a list of clicable defect keys\n  '[' ||\n  [Xray Defect].CurrentHierarchyMember.Name ||\n  ']' ||\n  --update the YOUR_JIRA_DOMAIN with right URL for you\n  '(http://YOUR_JIRA_DOMAIN/browse/' ||\n  [Xray Defect].CurrentHierarchyMember.Name || \n  ') ' || \n  [Measures].[Xray Defect status],\n  ', '\n)\n\n--set measure Formatting to Text -\u003e Markdown","format_string":"MarkdownFormatter"}]
}

See also