#2149 added new feature:
This is problematic for packages with many snapshots.
Situation:
- Package has many visual snapshot tests
- Many snaps cause package to be larger than 5mb
- These snaps a never used within revdep checks
Previous solution:
- R build Ignore the
tests/testthat/_snaps folder. Nothing is sent to CRAN and nothing is tested on CI. Local testing performs full snapshot testing.
Proposal:
- The default value of
fail_on_new should be determined by the existence of the _snaps folder: fail_on_new = fs::dir_exists(here::here("tests/testthat/_snaps"))
- Behavior:
- If no snaps exist during testing, do not fail on new snaps (new behavior)
- else fail then any new snap should cause a CI failure (current behavior)
#2149 added new feature:
This is problematic for packages with many snapshots.
Situation:
Previous solution:
tests/testthat/_snapsfolder. Nothing is sent to CRAN and nothing is tested on CI. Local testing performs full snapshot testing.Proposal:
fail_on_newshould be determined by the existence of the_snapsfolder:fail_on_new = fs::dir_exists(here::here("tests/testthat/_snaps"))