Reporting Strategy
How to structure and organize the reporting of CI test results to Currents
Last updated
How to structure and organize the reporting of CI test results to Currents
Last updated
This guide aims to help readers understand how to structure and organize the test result reporting in Currents. It covers key concepts such as project, runs and groups hierarchy, test result handling, and integration strategies.
By following this guide, users can optimize their test reporting workflow and gain clearer insights into their test runs.
The top-level entity representing reporting destination. Each organization can have multiple projects, there’s no limit on the number of projects.
You specify the project when running tests in your CI pipeline using environment variables CURRENTS_PROJECT_ID
or via reporter configuration. Please refer to reporter documentation for available options.
Each project maintains separate settings and data, with no crossover
Test results from different projects remain separate, even for identical tests.
Test history displays results only from the same project.
Performance metrics only include test recordings from the same project.
Each project has its own integrations with 3rd parties (see Integrations). However, multiple projects can be connected to the same destination.
For example, enabling a GitHub integration allows selecting the same GitHub organization and repository for different projects. However, this may result in duplicate PR comments originating from separate projects connected to the same repository.
A recording of test results from a CI run, uniquely identified by a CI Build ID, git commit information and CI provider execution details.
By default each run represents a build (or execution of a CI pipeline), however, you can send results from different stages of a pipeline or even different pipelines to the same run using the same CI Build ID value. See CI Build ID.
A collection of spec files and the corresponding test results. For example:
in Playwright you can create two Playwright projects that run the same tests for chrome
and firefox
- Currents will create a separate group, accordingly.
in Postman each “collection” corresponds a separate group.
Each group can contain multiple spec files and test results.
A file containing one or more test cases, identified by its reporter filesystem path. Currents collects certain performance metrics for specs. Spec file can contain zero or more test recordings.
A single test execution result, including attempts, attachments (screenshots, videos, traces, arbitrary attachments, visual diff results, annotations, error details. Each test record can have multiple attempts.
An attempt to run of a test case. Multiple attempts may occur depending on retry strategies.
You can implement various reporting scenarios using a combination of Projects, Runs and Groups. Consider the following popular scenarios.
You have a single product (and a repository) and a testing suite that runs as part of a CI pipeline, all tests run together, optionally multiple groups (e.g. chromium
and firefox
) will be automatically detected.
It is recommended to have a single project and create a unique run on every invocation of the CI pipeline.
Create a single project
Create a unique run for each CI invocation
Create single or multiple groups within each run
For bigger organizations, each product has its own repository and testing suite that runs as part of a CI pipeline.
Create a dedicated project for each product / repository
Create a single run for each CI invocation
Create a single or multiple groups for each run
A more complicated scenario is when you have a testing suite that runs in different "environments" and you need to decide how to organize the test results. For example:
running different Playwright projects in separate CI steps
running the same set of tests in multiple environments, e.g. based on locale (en-us
, en-ca
) or a domain (com
, .co.uk
)
running a subset of tests based on tags or glob pattern, e.g. playwright test --grep @desktop
running a subset of tests from different CI steps (or different pipelines) while separating the results
To implement the variety of possible scenarios you need to use the combination of Project, CI build ID, Groups and Tags, become familiar with the limitations and implications.
For example, consider testing an e-commerce web app with a slightly different set of Playwright tests for different domains (.com
, .co.uk
etc.).
You've defined the following
Let's consider various setups and the implications.
Regardless of the reporting strategy we recommend to annotate your tests and executions with tags. Adding tags allows granular access to the data.
Read more about using Playwright Tags to dynamically add tags to runs, groups and tests
Consider using removeTitleTag
in @currents/playwright to remove tags from test title and keep test history consistent
Aggregated run metrics are based on mixed results from the two types of runs. For example, suite size includes test from both groups. It is possible to refine the aggregation metrics to only include runs with particular tags. See
Test metrics are based on all runs, for example if test A runs in both environments, then both samples of the test will be included in its metrics (duration, flakiness rate, failure rate). It is possible to include only samples from particular run or group by using tags. See .
Scheduled automated reports are defined on project level and will contain results for both types of runs. It possible to refine the reports using .
Test results, including history contain results from all runs.. It is possible to filter the results only from particular run using ..