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

Find tests or tests/testthat subdirectory #14

krlmlr opened this issue Jun 14, 2016 · 2 comments

Find tests or tests/testthat subdirectory #14

krlmlr opened this issue Jun 14, 2016 · 2 comments


Copy link

krlmlr commented Jun 14, 2016

so that it works from Rstudio, testthat tests, and R CMD check.

I think this needs two changes:

  • A new criterion that checks the paths of the parent directory components, say, has_parent_dir()
  • Allowing to pass a vector to make_fix_root_file()

Usage would be:

find_test_file <- has_parent_dir("tests/testthat")$make_fix_file(c("tests/testthat", ""))

RE r-lib/testthat#425 (comment), CC @jennybc @richfitz.

@krlmlr krlmlr closed this as completed in 76a18ae Oct 23, 2016
krlmlr added a commit that referenced this issue Oct 23, 2016
- New `is_testthat` and `find_testthat_root_file()` that looks for `tests/testthat` root (#14).
- Improve navbar on project page.
- Uses `backports` to simplify compatibility with R 3.0.0.
- New `is_remake_project` and `find_remake_root_file()` that looks for remate project (#17).
Copy link
Member Author

krlmlr commented Oct 23, 2016

Documented at, does it work for you?

krlmlr added a commit that referenced this issue Nov 6, 2016
- Compatibility
    - Compatible with R >= 3.0.0 with the help of the `backports` package.

- New root criteria
    - `is_remake_project` and `find_remake_root_file()` look for [remake]( project (#17).
    - `is_testthat` and `find_testthat_root_file()` that looks for `tests/testthat` root (#14).
    - `from_wd`, useful for creating accessors to a known path (#11).

- Minor enhancement
    - Criteria can be combined with the `|` operator (#15).

- Documentation
    - Add package documentation with a few examples (#13).
    - Clarify difference between `find_file()` and `make_fix_file()` in vignette (#9).
    - Remove unexported functions from documentation and examples (#10).
    - Use `pkgdown` to create website.

- Testing
    - Use Travis instead of wercker. Travis tests three R versions, and OS X.
    - Improve AppVeyor testing.
Copy link

github-actions bot commented Dec 8, 2020

This old thread has been automatically locked. If you think you have found something related to this, please open a new issue and link to this old issue if necessary.

@github-actions github-actions bot locked and limited conversation to collaborators Dec 8, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
None yet
None yet

No branches or pull requests

1 participant