Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add support for test files in nested directories #1850

Open
wants to merge 6 commits into
base: main
Choose a base branch
from

Conversation

radbasa
Copy link

@radbasa radbasa commented Aug 29, 2023

Closes #1605

Allows the use of directories to organize test files.

The recursive argument is optional and defaults to FALSE.

  1. testthat::test_dir("tests/testthat/") will work as before. Just one single directory, and with the default reporter.
  2. testthat::test_dir("tests/testthat/", recursive = TRUE) to run all of the test scripts in all directories in tests/testthat/. testthat::test_dir() will still only see test scripts with ^test.*\\.[rR]$ filenames.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Provide optional recursive argument to test_dir()
1 participant