Hi ,
I already select noempty and a single test plan but i cant get the number by status
Please Help
Hi ,
I already select noempty and a single test plan but i cant get the number by status
Please Help
Measure Script:
CASE WHEN
[Xray Test Execution Status].CurrentMember.Level.Name = âStatusâ
THEN --count tests by last execution status
Cache(NonZero(Count(
Filter(
âiterate throug all Tests
Descendants([Xray Test].CurrentMember, [Xray Test].[Test]),
[Measures].[Xray Tests with executions] > 0 AND
Order(
âiterate through execution statuses for a selected Test
Filter([Xray Test Execution Status].[Status].Members,
[Measures].[Xray Tests with executions] > 0),
âorder statuses by execution date descending
DateParse(
Generate(
Tail(
âiterate through all dates when a Test was executed
Filter([Time].[Day].Members,
[Measures].[Xray Tests with executions] > 0
)).Item(0),
Format([Time].CurrentHierarchyMember.StartDate, âyyyy-mm-ddâ),
â,â)),
BDESC
âname of the last execution matches status in columns
).item(0) IS [Xray Test Execution Status].CurrentMember)
)))
ELSE --total count of tests with executions
([Measures].[Xray Tests with executions],
[Xray Test Execution Status].DefaultMember)
END
no one to help ?
Is really critical
Any newwwwwwwwwwwwwwws ???
Hi @nour,
The calculation for the last execution status within the report context (selected test plan, environment, fix version, or some other criteria) is complex. It takes a lot of resources to run through all tests and execution results and compare them. Unfortunately, for more significant data amounts, this might end with a timeout.
Here is another version (a somewhat faster) of how to calculate the last execution within a selected Test Plan, Environment, or some other criteria:
CASE WHEN
[Xray Test Execution Status].CurrentMember.Level.Name = "Status"
THEN
Cache(NonZero(Count(
Filter(
--iterate through Tests
Descendants([Xray Test].CurrentMember, [Xray Test].[Test]),
[Measures].[Xray Tests with executions] > 0 AND
Order(
--iterate through execution statuses for a selected Test
Filter([Xray Test Execution Status].[Status].Members,
[Measures].[Xray Tests with executions] > 0),
--order statuses by execution date descending
[Measures].[Xray Tests executed last date],
BDESC
--name of the last execution matches status in columns
).item(0) IS [Xray Test Execution Status].CurrentMember
))))
ELSE --total count of tests with executions
([Measures].[Xray Tests with executions],
[Xray Test Execution Status].DefaultMember)
END
Related Community topic:
An alternative is to import the last execution status for each Test and Test Plan combination using additional data import. The structure for additional data source might look like this:
Test - key of each test case to map additional data to the âXray Testâ dimension. Mark advanced options âKey columnâ and âSkip missingâ.
Test plan - key of the test plan to map additional data to the âXray Test Planâ dimension. Mark advanced options âKey columnâ and âSkip missingâ.
Test execution status - the last execution status in a test plan to map additional data to the âXray Test Execution Statusâ dimension. Mark advanced options âKey columnâ and âSkip missingâ.
Time - the date when the test was executed for the last time for a Test Plan to map additional data to the Time dimension. This column is optional if you use the âTimeâ dimension in the report.
Counter - number 1 to count unique test and test plan and status combinations. Import this column as a new measure âTests by last execution status in a Test Plan.â
More details on additional data import: Additional data import into Jira Issues cube - eazyBI for Jira
Best,
Zane / support@eazyBI.com
Hello ,
Thanks for the new script. It takes time also but at least at the end it shows values.
But it gives me wrong values:
and xray gives me :
When i investigate , i found that for the tests added to more than one test execution .They will have many last test execution status.
For example : if a test is :
-blocked in the first test execution
At the end we will have 2 Blocked instead of 1.
Can we take the last execution status from the last execution status?
OR, we just use a JQL like that issue in testPlanTests(âid_test_planâ,âExecution_statusâ) in eazybi as a measure ?
For the alternative you propose , i will study the feasibility in our case but now i should give something correct to the customer
Thank so much , you really helping me
NOUr
eazyBI does not duplicate Xray built-in reports or overview fields but pulls in data on all test runs from which eazyBI users could build custom analytics and reports suited for their quality assurance processes and key performance indicators. As a result, there might be slight differences between eazyBI and Xray reports at the Requirement or Test Plan level.
I believe the biggest concern is scheduled tests is status TO DO. The new tests do not have the last execution date (as it is only scheduled). And tests that have already failed and are scheduled again might have the latest execution data for status FAIL.
With additional data import, you may import a new measure that says how many tests are in each status for each test plan (a simpler version than a suggested solution). It will work. A drawback of a simple solution, it doesnât give more details about which tests were failing and which were passed. For this solution, you might want at least 3 columns of data:
Test Plan - key of the test plan to map additional data to the âIssueâ dimension. Mark advanced options âKey columnâ and âSkip missing.â
Execution status - the last execution status in a test plan to map additional data to the âXray Test Execution Statusâ dimension. Mark advanced options âKey columnâ and âSkip missingâ.
Count of tests with status - import this column as a new âMeasureâ.
Best,
Zane / support@eazyBI.com
Best,
hi,
if i want to present the last execution of certain Xray Test: Test Functionality = âregressionâ
what adjustments need to be done in the measure above ?
regards,
Tomer
Hi @Tomer,
You may adjust the given calculation and add more criteria by test issues properties to the filter part. You might want to use the expression [Xray Test].CurrentMember.Get()
and autocomplete to see which properties are available for Xray Test issues.
The update code might look like this:
Cache(NonZero(Count(
Filter(
--iterate through Tests
Descendants([Xray Test].CurrentMember, [Xray Test].[Test]),
--add filtering criteria by properties here
[Xray Test].CurrentMember.Get('Test Functionality') = "Regression" AND
[Measures].[Xray Tests with executions] > 0 AND
Order(
--iterate through execution statuses for a selected Test
Filter([Xray Test Execution Status].[Status].Members,
[Measures].[Xray Tests with executions] > 0),
--order statuses by execution date descending
[Measures].[Xray Tests executed last date],
BDESC
--name of the last execution matches status in columns
).item(0) IS [Xray Test Execution Status].CurrentMember
))))
Note the condition CASE WHEN is removed as property value could be verified at individual test level.
Best,
Zane / support@eazyBI.com