mirror of
https://github.com/msberends/AMR.git
synced 2025-11-06 15:58:53 +01:00
(v2.1.1.9163) cleanup
This commit is contained in:
@@ -146,14 +146,16 @@ for (i in seq_len(length(import_functions))) {
|
||||
fn <- names(import_functions)[i]
|
||||
pkg <- unname(import_functions[i])
|
||||
expect_true(pkg %in% suggests,
|
||||
info = paste0("package `", pkg, "` is not in Suggests"))
|
||||
info = paste0("package `", pkg, "` is not in Suggests")
|
||||
)
|
||||
# function should exist in foreign pkg namespace
|
||||
if (AMR:::pkg_is_available(pkg,
|
||||
also_load = FALSE,
|
||||
min_version = if (pkg == "dplyr") "1.0.0" else NULL
|
||||
also_load = FALSE,
|
||||
min_version = if (pkg == "dplyr") "1.0.0" else NULL
|
||||
)) {
|
||||
expect_true(!is.null(AMR:::import_fn(name = fn, pkg = pkg, error_on_fail = FALSE)),
|
||||
info = paste0("Function does not exist (anymore): function `", pkg, "::", fn, "()`"))
|
||||
info = paste0("Function does not exist (anymore): function `", pkg, "::", fn, "()`")
|
||||
)
|
||||
} else if (pkg != "rstudioapi") {
|
||||
warning("Package '", pkg, "' not available")
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user