diff --git a/DESCRIPTION b/DESCRIPTION index 7383c103d..128fb0e1b 100644 --- a/DESCRIPTION +++ b/DESCRIPTION @@ -35,7 +35,7 @@ Imports: R6 (>= 2.2.0), rlang (>= 1.1.0), utils, - waldo (>= 0.4.0), + waldo (>= 0.5.0), withr (>= 2.4.3) Suggests: covr, diff --git a/NEWS.md b/NEWS.md index 4d49a9c39..6254d30f2 100644 --- a/NEWS.md +++ b/NEWS.md @@ -1,5 +1,7 @@ # testthat (development version) +* `expect_snapshot()` differences no longer use quotes. + * `expect_error()`, `expect_warning()`, and `expect_message()` now correctly enforce that the condition is of the expected base class (e.g. error, warning, messsage) even when the `class` argument is used (#1168). diff --git a/R/snapshot-reporter.R b/R/snapshot-reporter.R index ba547458a..66a757510 100644 --- a/R/snapshot-reporter.R +++ b/R/snapshot-reporter.R @@ -57,7 +57,8 @@ SnapshotReporter <- R6::R6Class("SnapshotReporter", x = old, x_arg = "old", y = value, y_arg = "new", ..., - tolerance = tolerance + tolerance = tolerance, + quote_strings = FALSE ) if (length(comp) > 0L) {