# tests of functions in the checks.R script
context("checks")
test_that("check check_cols", {
# shouldn't throw an error
check_cols(calc_TURN(TUR_dat),
required_cols = c("epidate", "n_active", "n_active_adj"),
name = "TURN_df")
expect_error(check_cols(cars, required_cols = "blahhh"))
})
test_that("initial_check", {
expect_equal(initial_check(rp_raw), message("check passed"))
expect_message(initial_check(rp_raw, "Gastro_Intestinal"))
expect_error(initial_check(rp_raw, target_PouchTitle = "blaha"))
expect_error(initial_check(cars))
})
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.