Photo by Ricardo Resende on Unsplash


Code coverage is a measure of the amount of code being exercised by a set of tests. It is an indirect measure of test quality and completeness. This package is compatible with any testing methodology or framework and tracks coverage of both R code and compiled C/C++/FORTRAN code.

Today covr is the de-facto standard for tracking test coverage in the R community, with nearly 1000 CRAN packages having covr as a reverse dependency, and many more thousands using the package on GitHub.


Jim Hester
Software Engineer

I’m a Senior Software Engineer at Netflix and R package developer.


Being primarily a statistical language R lacks a number of common code analysis tools available for languages used more often for …

Since releasing covr I have gotten a couple of requests to explain how it works. This post is adapted from a vignette I wrote to try …


A deeper dive into how covr works, particularly how it deals with collecting coverage from multiple child R processes.

Code coverage records whether or not each line of code in a package is executed by the package’s tests. While it does not check …

A talk on my R packages, lintr and covr