tests/testthat/test-utils-rmd.R

test_that("pasteMd works properly", {

  expect_error(pasteMd())
  expect_warning(expect_error(pasteMd("path/to/file")))

  filename <- file.path("md", "test_doc.md")
  out <- pasteMd(filename)
  expect_snapshot_output(cat(out))
  expect_equal(class(out), "character")
  expect_equal(length(out), 1)
})
Yu-Group/simChef documentation built on March 25, 2024, 3:22 a.m.