The custom reporting within SpiraTest or SpiraTeam makes this very easy.
For example, the following query will return back a list of all the test runs in the current project that failed today and previously passed yesterday:
SELECT VALUE R1 FROM SpiraTestEntities.R_TestRuns AS R1
WHERE R1.PROJECT_ID = ${ProjectId}
AND R1.EXECUTION_STATUS_ID = 1 and TruncateTime(R1.END_DATE) = TruncateTime(CurrentUtcDateTime())
AND R1.TEST_CASE_ID IN (
SELECT VALUE R2.TEST_CASE_ID FROM SpiraTestEntities.R_TestRuns AS R2
WHERE R2.PROJECT_ID = ${ProjectId}
AND R2.EXECUTION_STATUS_ID = 2 AND TruncateTime(R2.END_DATE) = TruncateTime(AddDays(CurrentUtcDateTime(), -1)))
To use this query:
- Go to Administration
- Click on System > Edit Reports
- Create a new report
- Enter the name of the report
- Select the output formats (e.g. MS-Excel)
- Add a new custom section
- Enter the query from above
- Click the button to create the Default Template
- Save the section and the entire report.
- Now you can run this report
One of our customers (thanks Walter) modified this further to allow you to correlate the results by test set:
SELECT VALUE R1.TEST_CASE_ID
FROM SpiraTestEntities.R_TestRuns AS R1, SpiraTestEntities.R_TestRuns AS R2
WHERE R1.TEST_SET_ID = R2.TEST_SET_ID
AND R1.PROJECT_ID = ${ProjectId}
AND R2.PROJECT_ID = ${ProjectId}
AND R1.EXECUTION_STATUS_ID = 1
AND R2.EXECUTION_STATUS_ID = 2
AND TruncateTime(R1.END_DATE) = TruncateTime(CurrentUtcDateTime())
AND TruncateTime(R2.END_DATE) = TruncateTime(AddDays(CurrentUtcDateTime(), -1))