We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent abcab21 commit a9e9c0eCopy full SHA for a9e9c0e
tests/testthat/test-qenv_extract.R
@@ -1,13 +1,19 @@
1
testthat::test_that("`[.` returns empty qenv for names not in qenv", {
2
- data <- within(qenv(), {x = 1; a = 2})
+ data <- within(qenv(), {
3
+ x <- 1
4
+ a <- 2
5
+ })
6
testthat::expect_warning(
7
testthat::expect_equal(data["y"], qenv()),
8
"None of `names` elements exist in `qenv`. Returning empty `qenv`."
9
)
10
})
11
12
testthat::test_that("`[.` returns limited qenv for some names not in qenv", {
13
14
15
16
17
18
testthat::expect_equal(data[c("y", "a")], data["a"]),
19
"Some elements of `names` do not exist in `qenv`. Skipping those: y."
0 commit comments