Features

Everything gocov puts in front of your team.

Coverage shows up where code is reviewed, holds back merges that would lower it, and keeps the history in one place — for any language, on GitHub, GitLab and Bitbucket.

On the pull request

Diff coverage, not just a total

gocov fetches the pull request's diff from your forge and checks every changed line against the report. The question a reviewer has — of the lines this change touches, how many are tested? — gets a number and a list.

  • One comment per pull request, updated in place on every push
  • A coverage: X% (±Y%) status on every commit
  • GitHub: a check run with annotations in Files changed
  • Bitbucket: a Code Insights report with annotations in the diff
  • GitLab: the comment as a merge request note
Coverage in pull requests
A gocov comment on a pull request
gocovbot commented

gocov report for 9f31c2ab7e5d

  • Total coverage: 84.2% (+0.6%)
  • Gate: passed
  • Diff coverage: 91.7% (110/120 changed lines covered)

Uncovered changed lines:

FileLines
src/billing/invoice.ts87-89, 112-115
src/billing/refund.ts41, 56-57

Full report

At the merge

A gate that can't be talked down

Three optional rules per repository: a minimum total, a minimum diff coverage for the changed lines, and a maximum drop. A failing gate fails the commit's status, so branch protection or a merge check holds the pull request.

  • Failing uploads never become the baseline, so a re-run can't launder a failure
  • A pull request can't walk coverage down one allowed step at a time
  • No forge connection? The upload step can fail the pipeline instead
Coverage gate
Pull request checks: tests pass, gocov's coverage gate fails, and the merge is blocked
test Successful in 2m
gocov coverage: 81.9% (-2.3%) — diff coverage 52.4% is below the minimum 80%
Merging is blocked. A required check has failed.

Over time

History, trends and a badge

Every upload is kept. Each branch gets a trend, each file a line-by-line view with hit counts, fetched from the forge at the exact commit. A README badge shows the default branch's latest figure.

  • Deltas compare against the latest passing report, not just the previous commit
  • Public repositories get report pages anyone can open, no sign-in
  • Public report pages are listed in a sitemap, so they can be found
Public reports
Coverage over time main
82% 68% gate 70% 82.0%

In CI

Uploading fits the pipeline you have.

One step after your tests, whatever runs them.

No secret to paste

On GitHub Actions, GitLab CI and Bitbucket Pipelines the job proves which repository it is with a short-lived identity token from your forge. An upload token still works everywhere else.

Any test runner

Go profiles, LCOV, Cobertura, JaCoCo, Clover, SimpleCov, OpenCover and xccov. The format is detected from the file's content: no flag to set.

Several jobs, one report

Name each job's upload a part — backend, frontend, e2e — and gocov merges them per commit. A CI retry replaces its part instead of counting twice.

A wrapper for each CI

A GitHub Action, a GitLab component, a Bitbucket pipe and a CircleCI orb, plus one static CLI binary for everything else.

Fork pull requests

On public GitHub repositories, a contributor's fork PR gets its comment, check and status without any secret: gocov verifies the workflow run with GitHub.

Ignore what isn't yours

Generated code, mocks and vendored sources drop out of every figure through ignore patterns, set once per repository or per upload.

For coding agents

Close the coverage gap from a terminal

gocov report prints a commit's totals and the changed lines no test ran. An agent writes tests for those lines, pushes and reads the report again — no browser, no scraping. The same answer comes as JSON, from the read API, or over MCP.

Coding agents
$ gocov report
github/acme/widgets @ 7aa8f01 (feature, PR 247)
coverage: 88.0% (+0.4% vs c54dc2c), 2 parts
diff coverage: 82.6% (19/23 changed lines)
uncovered changed lines:
  cmd/gocov/oidc.go: 49-50, 57-58

Access

Your forge is the source of truth.

Sign in with your forge

GitHub, GitLab or Bitbucket. No passwords to keep, and workspaces come from the organizations, groups and workspaces you already belong to.

One-click connection

Install the GitHub App, or grant write access once on Bitbucket or GitLab. That connection is what posts statuses, comments and annotations.

Private stays private

A repository nobody may see answers exactly like one that doesn't exist. Public report pages follow the forge's own visibility and close when it changes.

Add coverage to your next pull request.

Moving from Codecov or Coveralls? The migration guide maps your settings over and keeps the old tool running until the numbers agree.