context("DESCRIPTION")
test_that("snapshotting broken DESCRIPTION files is an error", {
file <- tempfile()
# empty file
file.create(file)
expect_s3_class(renv_snapshot_description(file), "error")
# missing Version field
fields <- c(Type = "Package", Package = "test")
write.dcf(fields, file = file)
expect_s3_class(renv_snapshot_description(file), "error")
})
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.