Checking Test Coverage

The coverage of the 'testthat' tests can be assessed by generating a Test Coverage Report.

Test Coverage Reports can be generated using the R package 'covr', which can be installed by using:

install.packages("covr", dependencies=TRUE)
library("covr")

The Test Coverage Report is a set of HTML web pages. The commands to generate the Report, in this case for the 'dsBaseClient' package are:

pc <- covr::package_coverage(code=c("testthat::test_package('dsBaseClient')"))
covr::report(pc, file="/tmp/cr/index.html")

The Report will be automatically displayed when generated, and a copy placed in the "/tmp/cr", if the above commands are used.