tests/testthat/test_censor_values.R

test_that("censor values", {

  # run censor_values and test that NAs returned
  r <- censor_values(value = seq.int(1, 10, 1), censor_threshold = 5)
  expect_false(all(is.na(r)))
  expect_true(is.na(r[1]))
})

Try the HyMETT package in your browser

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

HyMETT documentation built on Nov. 23, 2023, 1:08 a.m.