Debian Codegraph @

tests/testthat.R

raw
1
2 library(testthat)
3 library(renv, warn.conflicts = FALSE)
4
5 if (!renv:::renv_tests_supported()) {
6 message("* renv does not support running tests on this platform.")
7 if (!interactive()) quit(status = 0L)
8 }
9
10 if (Sys.info()[["sysname"]] == "Linux") {
11 tools <- asNamespace("tools")
12 if (is.function(tools$R_user_dir)) {
13 cachedir <- tools$R_user_dir("renv", "cache")
14 dir.create(cachedir, recursive = TRUE, showWarnings = FALSE)
15 }
16 }
17
18 test_check("renv")