Skip to content

E2E test: group reliable report by product group

Jay McCure requested to merge jmc-reliable-report-groups into master

What does this MR do and why?

This MR changes the reliable report to additionally group tests by product group, enabling product teams and their stable counterparts to take ownership for their individual product groups and allow the Quality team to highlight product groups that have a large amount of reliable specs to be made reliable.

Some refactoring and additional unit tests added also.

Terminal output has also changed to group by product group. Slack message has not changed, it shows the stage summary.

Screenshots or screen recordings

Before After
Screenshot_2023-10-23_at_17.22.25 Screenshot_2023-10-23_at_16.08.37
Screenshot_2023-10-23_at_17.21.22 Screenshot_2023-10-23_at_17.20.45

Example report

I have generated a report using this MR in a test project here: jay_mccure/jm_rr#1 (closed) (this won't render the labels as it is not a part of the gitlab project)

For comparison, this is the latest reliable report #429028 (closed) (useful for verifying that the numbers haven't changed)

How to set up and validate locally

NOTE: Change this line to be a project on your GDK: https://gitlab.com/gitlab-org/gitlab/-/blob/master/qa/qa/tools/reliable_report.rb#L31-31

From the qa dir, ensure you are pointing to your GDK (alternatively could use a test project on gitlab.com):

GITLAB_ACCESS_TOKEN=<token for your GDK> CI_API_V4_URL=http://gdk.test:3000/api/v4/ QA_INFLUXDB_URL=https://influxdb.quality.gitlab.net QA_INFLUXDB_TOKEN=<1password> bundle exec rake "reliable_spec_report[14, true]"

Once the report has been generated, you can view the report in your GDK. You can also copy the contents of the report and preview a new issue on gitlab.com to see the labels render correctly.

The above command is intentionally missing SLACK_WEBHOOK variable as we do not want to post to Slack for testing. This will cause an error but the issue will be created.

MR acceptance checklist

This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.

Edited by Jay McCure

Merge request reports