tests/testthat/test-n_valid.R

test_vector <- c(1, 1, NA_real_, 2, 3, 3, 4, 3, 1, NA_real_)

test_that("n_valid works", {
  expect_equal(n_valid(test_vector), 8)
})
INS-Basel/hsrtools documentation built on April 20, 2024, 5:15 p.m.