From b6fce43f312134bdb4db0a81bf5e8f9ac891575b Mon Sep 17 00:00:00 2001 From: Hadley Wickham Date: Tue, 1 Nov 2022 11:21:45 -0500 Subject: [PATCH] Fix for dev purrr --- tests/testthat/test-util.R | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/tests/testthat/test-util.R b/tests/testthat/test-util.R index 73ec20a..c20e2ac 100644 --- a/tests/testthat/test-util.R +++ b/tests/testthat/test-util.R @@ -44,9 +44,8 @@ test_that("rlmap returns NULL unaltered", { expect_null(rlmap(list(foo=NULL), function(x) x)$foo) }) -test_that("vec_depth doesn't attempt to measure the depth of errors", { +test_that("vec_depth can measure the depth of errors", { err <- tryCatch(stop("oops"), error=function(e) {e}) - expect_error(purrr::vec_depth(err)) expect_equal(vec_depth(err), 1) })