inst/tinytest/test_glimpse.R

expect_equal(
  {
    tmp <- tempfile()
    on.exit(unlink(tmp), add = TRUE)
    sink(tmp)
    x <- glimpse(mtcars)
    sink(NULL)
    x
  },
  mtcars,
  info = "The object is returned invisibly"
)
nathaneastwood/poorman documentation built on Feb. 10, 2024, 1:41 p.m.