tests/testthat/test-nothing.R

test_that("nothing returns a maybe value", {
  nothing() %>% is_maybe() %>% expect_true()
})

test_that("nothing returns a nothing value", {
  nothing() %>% is_nothing() %>% expect_true()
})

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.