Nothing
spec <- hd_spec(survey_df, "age", "pct")
opts <- hd_opts()
test_that("validate_fig_inputs: passes for all valid inputs", {
expect_invisible(
validate_fig_inputs(spec, opts, "column", "dynamic", list()))
})
test_that("validate_fig_inputs: rejects non-hd_spec", {
expect_error(
validate_fig_inputs(list(), opts, "column", "dynamic", list()),
"hd_spec")
})
test_that("validate_fig_inputs: rejects non-hd_opts", {
expect_error(
validate_fig_inputs(spec, list(), "column", "dynamic", list()),
"hd_opts")
})
test_that("validate_fig_inputs: rejects unknown geometry", {
expect_error(
validate_fig_inputs(spec, opts, "violin", "dynamic", list()),
"Unknown geometry")
})
test_that("validate_fig_inputs: rejects unknown backend", {
expect_error(
validate_fig_inputs(spec, opts, "column", "plotly", list()),
"Unknown backend")
})
test_that("validate_fig_inputs: enforces required geometry args", {
expect_error(
validate_fig_inputs(spec, opts, "arearange", "dynamic", list()),
"Missing required")
expect_invisible(
validate_fig_inputs(spec, opts, "arearange", "dynamic",
list(ymin = "lo", ymax = "hi")))
})
test_that("validate_fig_inputs: pie has no required args", {
expect_invisible(
validate_fig_inputs(spec, opts, "pie", "dynamic", list()))
})
Any scripts or data that you put into this service are public.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.