tests/testthat/test-should_inform_unspecified.R

test_that("should_inform_unspecified defaults to TRUE", {
  withr::local_options(tibblify.show_unspecified = NULL)
  expect_true(should_inform_unspecified())
})

test_that("should_inform_unspecified respects the option", {
  withr::local_options(tibblify.show_unspecified = TRUE)
  expect_true(should_inform_unspecified())
  withr::local_options(tibblify.show_unspecified = FALSE)
  expect_false(should_inform_unspecified())
})

Try the tibblify package in your browser

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

tibblify documentation built on May 9, 2026, 5:07 p.m.