skip {testthat} | R Documentation |
This function allows you to skip a test if it's not currently available. This will produce an informative message, but will not cause the test suite to fail.
skip(message) skip_if_not(condition, message = deparse(substitute(condition))) skip_if_not_installed(pkg) skip_on_cran() skip_on_os(os) skip_on_travis() skip_on_appveyor() skip_on_bioc()
message |
A message describing why the test was skipped. |
condition |
Boolean condition to check. If not |
pkg |
Name of package to check for |
os |
Character vector of system names. Supported values are
|
skip_if_not()
works like stopifnot
, generating
a message automatically based on the first argument.
skip_on_cran()
skips tests on CRAN, using the NOT_CRAN
environment variable set by devtools.
skip_on_travis()
skips tests on travis by inspecting the
TRAVIS
environment variable.
skip_on_appveyor()
skips tests on appveyor by inspecting the
APPVEYOR
environment variable.
skip_on_bioc()
skips tests on Bioconductor by inspecting the
BBS_HOME
environment variable.
skip_if_not_installed()
skips a tests if a package is not installed
(useful for suggested packages).
if (FALSE) skip("No internet connection")