library(testthat)
## Testing the eq_map
test_that("The output is leaflet",
{data("raw_data")
data <- eq_clean_data(raw_data)
input_data <- dplyr::filter(data, COUNTRY == "MEXICO" &
lubridate::year(date) >= 2000)
leaf <- eq_map(input_data, annot_col = "date")
expect_that(leaf, is_a("leaflet"))
})
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.