test_that("tests for tags_df", {
x <- make_linelist(cars, age = "speed", date_reporting = "dist")
y <- cars[c("dist", "speed")]
names(y) <- c("date_reporting", "age")
# errors
msg <- "Must inherit from class 'linelist', but has class 'data.frame'."
expect_error(tags_df(cars), msg)
# functionality
expect_identical(tags_df(x), y)
})
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.