Repository navigation
-
%==%diagnostics normalizestr()output by removing the common leading spaces, so failure messages and snapshots are the same across R versions (R-devel stopped padding top-levelstr()output). -
Removed support for sourcing global
helper*.Rfiles placed directly in the parent of the test directory (e.g.,tests/helper.R). Put shared helpers in a siblinghelpers/directory (e.g.,tests/helpers/) instead. -
has_match()gained afixedargument (passed togrepl()) to matchpatternliterally. A fixed search no longer has the Perl/dotall flag applied (previouslyfixed = TRUEvia...left a literal(?s)prepended to the pattern, so the match failed, andgrepl()warned aboutperl = TRUEbeing ignored). -
has_match()treats apatternwrapped inI()as a shorthand forfixed = TRUE, i.e.has_match(x, I(p))matchespliterally. -
has_match()accepts!patternas a shorthand fornegate = TRUE, i.e.has_match(x, !p)tests thatxdoes not matchp. -
test_pkg()temporarily unsets the environment variableR_TESTS(whichR CMD checksets to a relative path,startup.Rs) while tests run. Previously child R processes started from tests (e.g., future or parallel workers) failed at startup because the relative path could not be resolved from the test directory.