tests/testthat/test-helpers.R

test_that("%||% works", {
  expect_equal(NULL %||% "a", "a")
  expect_equal("b" %||% NULL, "b")
  expect_equal("c" %||% "d", "c")
})

Try the ooplah package in your browser

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

ooplah documentation built on Jan. 21, 2022, 5:07 p.m.