tests/testthat/TestNestedTestDirs/tests/testthat/test-nested-dir.R

# used for testing the extraction of srcrefs pertaining to tests, which assumes 
# srcrefs within working directory

if (Sys.getenv("COVR_TEST_NESTED") == "TRUE") {
  test_dir("./nested_tests")

  # keep.source needed to extract test trace
  source("./nested_tests/test-a.R", keep.source = TRUE)  
}

Try the covr package in your browser

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

covr documentation built on Nov. 9, 2023, 9:07 a.m.