The coverage is that of percent_coverage(), rounded down to a whole
percent so that only fully covered code shows 100%. The badge is green for
coverage of 90% or more, yellow for 75% or more and red below that, the
same thresholds used by report(). Coverage without any lines of code,
such as that of a package with no R code, shows as unknown on a gray
badge.
The badge is a plain file, so on a continuous integration service it needs
to be stored somewhere that the README can link to, e.g. committed to a
separate branch of the repository.
system.file("workflows", "test-coverage-badge.yaml", package = "covr") is
a GitHub Actions workflow that does this.