From 42c7d6be0507f30ae4ae6fc47a14c123a12b1932 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Kirill=20M=C3=BCller?= Date: Sun, 16 Jul 2023 20:45:11 +0200 Subject: [PATCH] Improve test --- tests/testthat/_snaps/dplyr.md | 7 ------- tests/testthat/test-dplyr.R | 5 +---- 2 files changed, 1 insertion(+), 11 deletions(-) delete mode 100644 tests/testthat/_snaps/dplyr.md diff --git a/tests/testthat/_snaps/dplyr.md b/tests/testthat/_snaps/dplyr.md deleted file mode 100644 index ac76117e..00000000 --- a/tests/testthat/_snaps/dplyr.md +++ /dev/null @@ -1,7 +0,0 @@ -# no homonyms - - Code - names_common[!same] - Output - character(0) - diff --git a/tests/testthat/test-dplyr.R b/tests/testthat/test-dplyr.R index 273b8152..476d1372 100644 --- a/tests/testthat/test-dplyr.R +++ b/tests/testthat/test-dplyr.R @@ -16,8 +16,5 @@ test_that("no homonyms", { objs_dplyr <- mget(names_common, dplyr) objs_duckplyr <- mget(names_common, duckplyr) - same <- purrr::map2_lgl(objs_dplyr, objs_duckplyr, identical) - expect_snapshot({ - names_common[!same] - }) + expect_identical(objs_duckplyr, objs_dplyr[names(objs_duckplyr)]) })