Skip to content

Commit

Permalink
vars() is deprecated
Browse files Browse the repository at this point in the history
  • Loading branch information
larmarange committed Aug 23, 2024
1 parent 3eb9918 commit 114d338
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 11 deletions.
5 changes: 0 additions & 5 deletions tests/testthat/test-select_helpers.R
Original file line number Diff line number Diff line change
Expand Up @@ -32,11 +32,6 @@ test_that("select_helpers: .select_to_varnames", {
.select_to_varnames(select = NULL, data = mtcars),
NULL
)

expect_equal(
.select_to_varnames(select = vars(dplyr::everything(), -mpg), data = mtcars),
dplyr::select(mtcars, dplyr::everything(), -mpg) |> colnames()
)
})

test_that("select_helpers: all_*()", {
Expand Down
6 changes: 0 additions & 6 deletions tests/testthat/test-select_variables.R
Original file line number Diff line number Diff line change
Expand Up @@ -44,12 +44,6 @@ test_that("tidy_select_variables() works for basic models", {
res |> tidy_select_variables(include = stage)
)

# testing vars() selector
expect_equivalent(
res |> tidy_select_variables(include = vars(grade, trt)),
res |> tidy_select_variables(include = c(grade, trt))
)

# no error when none selected
expect_error(
res |> tidy_select_variables(include = starts_with("zzzzzzz")),
Expand Down

0 comments on commit 114d338

Please sign in to comment.