context("data fun")
test_that("download and parse generated data functions", {
ns <- asNamespace("icd.data")
for (b in c(
.data_names,
"icd10cm_latest"
)) {
inf <- paste("Data fun name:", b)
expect_true(.exists_in_ns(paste0("get_", b)), info = inf)
if (.offline() && !.exists_in_cache(b)) {
skip(paste(
"Regardless of interactivity, don't download during tests and",
inf, "not in cache"
))
}
f <- .get_fetcher_fun(b)
expect_is(f(), "data.frame", info = inf)
}
})
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.