tests/testthat/test-cut_r.R

test_that("cut_r return a data.frame", {
  expect_error(cut_r(2))
  expect_error(cut_r(2.6))
  expect_equal(nrow(cut_r(193)), 4)
  # test NA
  expect_error(cut_r(NA))
})

Try the Keng package in your browser

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

Keng documentation built on April 4, 2025, 1:37 a.m.