I am encountering issues with here::here() not being able to find the root directory of a package when it's called from inside the tests/testthat folder.
I have a .here file, a DESCRIPTION file, and an Rproj file two levels up from the tests/testthat as one might expect, but dr_here indicates the following:
- contains a file `.here`
- contains a file matching `[.]Rproj$` with contents matching `^Version: ` in the first line
- contains a file `DESCRIPTION` with contents matching `^Package: `
- contains a file `remake.yml`
- contains a file `.projectile`
- contains a directory `.git`
- contains a file `.git` with contents matching `^gitdir: `
- contains a directory `.svn`
It seems like it's not traversing up the tree to the proper parents given this output.
The following does work to find the root directory however:
rprojroot::find_root_file(criterion = rprojroot::has_file("DESCRIPTION"))