tests/testthat/setup.R

# Redirect all graphics to a null device for the test session.
# This prevents bare plot() calls and vdiffr snapshot rendering from
# appearing in the interactive graphics device (e.g. the RStudio viewer).
# vdiffr opens its own svglite device on top of this one, so snapshot
# tests are unaffected.
pdf(NULL)
withr::defer(dev.off(), teardown_env())

Try the TreeDist package in your browser

Any scripts or data that you put into this service are public.

TreeDist documentation built on June 10, 2026, 5:06 p.m.