Include sub-group projects in Group Code Coverage feature set

Everyone can contribute. Help move this issue forward while earning points, leveling up and collecting rewards.

Status (as of 2026-11-24): Not committed. In Backlog, no milestone.

Release notes

Problem to solve

Group coverage goes blind the moment you organize by subgroup.

Teams structure projects into subgroups. The group Repository analytics page counts only projects sitting directly in the group, yet the docs describe it as showing "test coverage data for all projects in a group". Leaders, test managers and auditors get a figure that looks like the group's total and isn't. The only route to the real number is to look up each project by hand, or to write and maintain a custom GraphQL report, then explain why it doesn't match the product. Some requesters report coverage as an audit measure, so they have no figure they can show an auditor from GitLab itself.

Who feels it: anyone accountable for coverage across more than one team: engineering leaders, test managers, auditors.

Jobs to be done

  1. Know total test coverage across a group and all its subgroups.
  2. Give auditors an exportable record of that coverage.
  3. See coverage per subgroup to find where it is low.

Customer outcomes (to be measured; not yet validated)

  • Time to a group-wide coverage figure: from per-project lookups or a custom script to one page view.
  • Share of a hierarchy's projects included in the group figure: from direct children only to all of them.
  • An export that covers every project in the hierarchy for the chosen period.
  • The page, graph and export show the same numbers.

Evidence

  • At least 11 customer requests since 2022, across Premium and Ultimate and across GitLab.com, Self-Managed and Dedicated.
  • 75 upvotes; open since October 2020.
  • Requesters who use the GraphQL workaround say they would rather have the dashboards.

What we know today

Read from master on 2026-11-24.

  • The summary, graph and CSV filter on the project's direct parent group, so subgroup projects drop out (model, finder).
  • Listing subgroup projects in the table is a small frontend change. On its own, the table would then disagree with the totals above it.
  • The CSV is capped at 1,000 rows, newest first, one row per job per project per day. It shows the project name, not its path (finder, controller).
  • Reports cover at most 90 days.
  • The group average is a mean across project-and-job rows, not across projects.
  • Coverage results live in a separate database from group and project data, so "this group and everything beneath it" needs a design that avoids a cross-database join.

Proposal

Direction only. Not committed.

  • Make subgroup inclusion opt-in. Default-on would change existing totals, graph and CSV.
  • When it is on, the totals, graph, table and export agree.
  • Export: add the project path, and decide how it works at organization size (see open questions).
  • GraphQL: let codeCoverageActivities include subgroups.
  • Later: a per-subgroup view. A design with a subgroups tab and a projects tab was agreed in October 2025.

Open questions

  1. What should the export do at organization size: raise the cap, aggregate, or export in the background?
  2. Should totals and export ship before the per-subgroup view?
  3. Should the average be per project or per job row?

Workaround

  1. Per-subgroup trends: the GraphQL query in this comment. It covers at most 90 days and skips the top-level group's own projects.
  2. Latest coverage for every project in the hierarchy, with pagination. It has no trend data and no CSV, and averaging its results won't match the page's definition:
GraphQL query
query GroupCoverage($fullPath: ID!, $after: String) {
  group(fullPath: $fullPath) {
    projects(includeSubgroups: true, first: 100, after: $after) {
      pageInfo {
        hasNextPage
        endCursor
      }
      nodes {
        fullPath
        archived
        codeCoverageSummary {
          averageCoverage
          coverageCount
          lastUpdatedOn
        }
      }
    }
  }
}

Run it in /-/graphql-explorer with { "fullPath": "my-org", "after": null }. Repeat with the endCursor value until hasNextPage is false. Projects that never reported coverage show codeCoverageSummary: null.

Previous "Problem to solve" and "Proposal" (original text)

Problem to solve

As a Director of App Dev, I want to see coverage data from projects that belong to sub-groups of my group, so I can get a true sense of TOTAL test coverage in the group.

Proposal

  • Add to the query that sub-groups are parsed and data sent back in the GraphQL API
  • If this is deemed not performant (takes 2x the current time on gitlab.org with all of its sub-projects maybe?) let's talk about making this an option for the user in the interface.
  • Graph should now calculate average of all coverage jobs for group and sub-group projects with coverage
  • Table should display data from group and sub-group projects (UX we might think about how to display this, maybe just a * on the project name or something?)
  • The .csv should include the sub-group project data (Same note as item above about including a way to indicate sub-group projects
Edited by Darren Eastman