tests/testthat/test-get_category_strings.R

test_that("get_category_strings() namespaces", {
  expect_true(requireNamespace("data.table", quietly = TRUE))
})

test_that("get_category_strings() category names",{
  expect_snapshot(RcensusPkg::get_category_strings(get_names = TRUE))
})

test_that("get_category_strings() race", {
  expect_snapshot(RcensusPkg::get_category_strings(name = "race"))
})

Try the RcensusPkg package in your browser

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

RcensusPkg documentation built on April 11, 2025, 6:16 p.m.