← Back to all sparks
V

vdiffr

INFRA · APIS
Velocity0.0

Visual regression testing of R graphics as part of a testthat suite

vdiffr finished its job in 2021 and has been tracking compilers ever since.

testingsnapshotssvgtestthatr-libmaintenance
Current state
vdiffr generates deterministic SVG snapshots so plot changes show up as test failures. Its recent history is almost entirely toolchain: UCRT Windows compatibility twice, a revert to C++11 to work around a GCC issue, and renaming the internal SVG device so it stops colliding with svglite. The only functional additions in view are snapshot variants in 1.0.8 and a testthat fix so snapshots are no longer auto-deleted when a test errors or skips. The last release was October 2024.
Where it's heading
The package reached its intended shape at 1.0.0, when snapshot management moved to testthat and vdiffr shed most of its own R and JavaScript code to become a reproducible SVG engine and nothing more. There is not much left to add to that, and the release stream since reads accordingly: it moves when a compiler, an R version, or testthat moves. For a testing dependency this is a healthy end state, though it does mean the package inherits whatever the graphics engine does to snapshot stability.
Prediction
The entries do not support predicting a feature release. The likely next change is a compatibility fix prompted by a compiler or a testthat change, as every release since 1.0.2 has been.

Recent moves

  1. 1y ago

    Snapshot variants supported

    Adds support for snapshot variants, so the same plot can have different accepted snapshots per platform or R version. That is the standard escape hatch for graphics tests that legitimately differ between environments.

    View source ↗
  2. 2y ago

    Revert to C++11 for a GCC workaround

    Reverts to C++11 to work around a GCC issue. A compiler workaround with no user-visible effect.

    View source ↗
  3. 2y ago

    Rename internal SVG device to avoid svglite collision

    Renames vdiffr's internal SVG device so it can be told apart from svglite's. A naming collision between two packages that share an ancestry.

    View source ↗
  4. 4y ago

    UCRT Windows compatibility under Rtools42

    Compatibility with the UCRT build of Windows under Rtools42, one day after the same fix for UCRT generally. Toolchain follow-up.

    View source ↗
  5. 4y ago

    UCRT Windows compatibility

    Compatibility with the UCRT build of Windows, contributed externally. Build-level change only.

    View source ↗
  6. 5y ago

    Snapshots survive errored and skipped tests

    Stops testthat auto-deleting snapshot files that were not regenerated because a test errored or skipped. Without this, one unrelated failure could silently wipe accepted snapshots and turn a red test run into a much larger cleanup.

    View source ↗