tests/testthat/test_reportingUtility.R

context("Test reporting utility functions")

test_that("A report header is correctly set", {
      
	title <- getMdHeader("A title")
	expect_type(title, "character")
	expect_identical(object = title, expected = "\n# A title\n")
	
})

test_that("A level is correctly set to a report header", {
      
	titleTwo <- getMdHeader("A title", level = 2)
	expect_match(object = titleTwo, regexp = "##")
      
})

Try the clinDataReview package in your browser

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

clinDataReview documentation built on April 12, 2025, 1:14 a.m.