tests/testthat/test-deprec-tibble.R

test_that("add_rownames is deprecated", {
  expect_warning(
    res <- mtcars %>% add_rownames("Make&Model"),
    "deprecated"
  )
  expect_equal(class(res), c("tbl_df", "tbl", "data.frame"))
})

Try the dplyr package in your browser

Any scripts or data that you put into this service are public.

dplyr documentation built on Nov. 17, 2023, 5:08 p.m.