Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 3 Current »

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.

  • No labels