source_file {testthat} | R Documentation |
The expectation is that the files can be sourced in alphabetical order.
Helper scripts are R scripts accompanying test scripts but prefixed by
helper
. These scripts are run once before the tests are run.
source_file(path, env = test_env(), chdir = TRUE, encoding = "unknown", wrap = TRUE) source_dir(path, pattern = "\\.[rR]$", env = test_env(), chdir = TRUE, wrap = TRUE) source_test_helpers(path = "tests/testthat", env = test_env()) source_test_setup(path = "tests/testthat", env = test_env()) source_test_teardown(path = "tests/testthat", env = test_env())
path |
Path to tests |
env |
Environment in which to evaluate code. |
chdir |
Change working directory to |
encoding |
Deprecated |
wrap |
Automatically wrap all code within |
pattern |
Regular expression used to filter files |