tests/testthat/test-nocite_references.R

test_that("nocite_references works", {
  citekeys <- cite_packages(output = "citekeys", out.dir = tempdir(), pkgs = "grateful")
  out <- nocite_references(citekeys)
  expect_equal(out,
               structure("---\nnocite: |\n\t @grateful \n...",
                         class = "knit_asis",
                         knit_cacheable = NA))
})

Try the grateful package in your browser

Any scripts or data that you put into this service are public.

grateful documentation built on April 3, 2025, 6:05 p.m.