test_that("change_maintainer_email checks fields", {
path <- withr::local_tempfile()
desc <- desc::desc(text = "")
desc$write(path)
expect_snapshot(change_maintainer_email(path, "x@example.com"), error = TRUE)
desc <- desc::desc(text = c(
"Authors@R: person('x', 'y')",
"Maintainer: foo <foo@example.com>"
))
desc$write(path)
expect_snapshot(change_maintainer_email(path, "x@example.com"), error = TRUE)
})
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.