View source: R/run_covr_skip_nstf.R
| get_nstf_test_path | R Documentation |
This internal NSTF utility detects and returns all relevant test directories
used by an R package. It combines declared test framework flags in
test_pkg_data with filesystem-based detection for robustness.
get_nstf_test_path(test_pkg_data, testdir)
test_pkg_data |
|
testdir |
|
Supported directory layouts include:
testthat: tests/testthat/
testit (standard): tests/testit/
testit (nonstandard): both tests/test-ci/ and
tests/test-cran/ present, using tests/ as the root
base R tests: *.R files directly under tests/
Bioconductor unit tests: inst/unitTests/
If no test directory of any supported type is detected, the output falls back
to a single entry:
default_tests_root = <tests/>.
list. A named list of character vectors giving all detected
applicable test directories. Possible names include:
testthat – path to tests/testthat/
testit – path to tests/testit/
nonstandard_testit_root – tests/ when both
test-ci/ and test-cran/ exist
base_tests_root – tests/ if *.R files exist directly
bioc_unitTests – path to inst/unitTests/
default_tests_root – fallback tests/ directory
The returned list describes all test frameworks detected in a package. Each
element is a filesystem path that the NSTF workflow should consider when
identifying or running tests. Duplicate paths (e.g., multiple roles pointing
to tests/) are automatically removed.
Other nstf_utility:
check_covr_skip_nstf(),
check_covr_skip_testit(),
get_source_test_mapping_nstf(),
run_covr_skip_nstf()
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.