tests/testthat/test-print.R

test_that("print method prints correctly", {
  print(nothing()) %>% expect_output("Nothing")

  print(just(1)) %>% expect_output("Just")
  print(just(1)) %>% expect_output("1")
})

Try the maybe package in your browser

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

maybe documentation built on Aug. 7, 2023, 5:11 p.m.