tests/testthat/test-ornament.R

test_that("ornament", {
  expect_snapshot({
    new_ornament(c("abc", "de"))
    new_ornament(c("abc", "de"), align = "right")
    new_ornament(c("abc", "de"), width = 5, align = "right")
    format(new_ornament(c("abc", "de")))
    format(new_ornament(c("abc", "de")), width = 5)
  })
})

test_that("vertical", {
  expect_snapshot({
    as_glue(c("abc", "de"))
  })
})

Try the pillar package in your browser

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

pillar documentation built on March 31, 2023, 10:19 p.m.