tests/testthat/test-badwords.R

context("Check package name for bad words")

test_that("Catches bad word", {
  skip_on_cran()

  expect_identical("hell", get_bad_words("hell")[[1L]])
})

test_that("Passes safe word", {
  skip_on_cran()

  expect_true(length(get_bad_words("happy")) == 0)
})

Try the available package in your browser

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

available documentation built on July 11, 2022, 1:05 a.m.