{"id":19466869,"url":"https://github.com/digio/covermate","last_synced_at":"2026-06-13T03:02:53.998Z","repository":{"id":101108315,"uuid":"202448392","full_name":"digio/covermate","owner":"digio","description":"Covermate is a tool to assist with managing code-coverage metrics in Go codebases","archived":false,"fork":false,"pushed_at":"2019-11-12T12:00:51.000Z","size":17,"stargazers_count":2,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2026-01-14T23:29:43.715Z","etag":null,"topics":["coverage","go"],"latest_commit_sha":null,"homepage":"","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/digio.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null}},"created_at":"2019-08-15T00:56:41.000Z","updated_at":"2019-11-12T11:59:23.000Z","dependencies_parsed_at":"2023-07-18T11:28:12.971Z","dependency_job_id":null,"html_url":"https://github.com/digio/covermate","commit_stats":null,"previous_names":["mantel-digio/covermate"],"tags_count":5,"template":false,"template_full_name":null,"purl":"pkg:github/digio/covermate","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/digio%2Fcovermate","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/digio%2Fcovermate/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/digio%2Fcovermate/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/digio%2Fcovermate/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/digio","download_url":"https://codeload.github.com/digio/covermate/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/digio%2Fcovermate/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":34270417,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-26T15:22:16.424Z","status":"online","status_checked_at":"2026-06-13T02:00:06.617Z","response_time":62,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["coverage","go"],"created_at":"2024-11-10T18:31:15.218Z","updated_at":"2026-06-13T03:02:53.980Z","avatar_url":"https://github.com/digio.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"[![Build Status](https://travis-ci.org/digio/covermate.svg?branch=master)](https://travis-ci.org/digio/covermate)\n\n# Covermate\n\nCovermate is a tool to assist with managing code-coverage metrics.  Go provides builtin tools for assessing code test-coverage.  Covermate extends the capabilities of the Go test-coverage report by allowing coverage-omissions to be flagged, or tagged as exclusions. This allows untested code to be tracked and managed.\n\nCovermate can be integrated into a CI pipeline to verify that untested blocks of code are specifically excluded, and also that the overall coverage meets a specified threshold.\n\nCovermate will exit with non-zero if:\n- There is a block of code which is not tested and does not have a `// nocover` comment.\n- The overall code coverage does not meet a specified threshold.\n\n*Note:* As per -coverprofile, packages with no tests are ignored.\n\n*Note:* As per -coverprofile, coverage is package-specific.  i.e. code is only considered covered, if it is called from a test within the same package.\n\n## Installion\n\n```bash\ngo install github.com/digio/covermate\n```\n\n## Usage\n```\nusage: covermate [\u003cflags\u003e]\n\nFlags:\n      --help                     Show context-sensitive help (also try --help-long and --help-man).\n  -f, --filename=\"coverage.out\"  coverage report from go test\n  -t, --tag=\"nocover\"            comment tag to exclude blocks from mandatory coverage\n  -T, --threshold=-1             minimum required overall coverage\n```\n\nCovermate depends on the coverage report generated by `go test` with the  `-coverprofile` option.\n\nTo execute the commands together:\n```bash\ngo test ./... -coverprofile=coverage.out \u0026\u0026 covermate\n```\n\nBy default covermate will not assess the overall level of code coverage.  A threshold can be set by \nproviding a value between 0 and 100 with the -T option.  If a theshold is set, and the total coverage is\nbelow the specified level, covermate will exit with an error.\n\n## Example\n\nIf a block of code has no test coverage, it must include a specific tag in the comments (`nocover` by default), or it will generate an error.\n\n```go\n    // Depending on the nature of `data`, it may not be possible to make `json.Marshal()` return an error.\n    data, err := createData()\n    if err != nil {\n        return err // if this block is not tested, covermate will exit with error\n    }\n    b, err := json.Marshal(data)\n    if err != nil {\n        return err // nocover - this block is tagged as being excluded from mandatory code coverage\n    }\n```","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdigio%2Fcovermate","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdigio%2Fcovermate","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdigio%2Fcovermate/lists"}