tests/testthat/resources/code.R
raw| 1 | |
| 2 | # should be parsed as dependencies (use only lower-case letters for package names) |
| 3 | library(a) |
| 4 | library("b") |
| 5 | base::library(c) |
| 6 | base::library("d", character.only = TRUE) |
| 7 | requireNamespace("e") |
| 8 | base::requireNamespace("f", quietly = TRUE) |
| 9 | xfun::pkg_attach(c("g", "h")) |
| 10 | pkg_attach2("i", "j") |
| 11 | k::foo() |
| 12 | l:::bar() |
| 13 | "m"::baz() |
| 14 | |
| 15 | # should NOT be parsed as dependencies (use only upper-case names for package names) |
| 16 | library(A, character.only = TRUE) |