From a2999ea6c041be7415099b309d464833857dbf44 Mon Sep 17 00:00:00 2001 From: Andrew Gene Brown Date: Fri, 31 May 2024 17:03:30 -0700 Subject: [PATCH] glom: add test for #180 --- tests/testthat/test-glom.R | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/tests/testthat/test-glom.R b/tests/testthat/test-glom.R index fa5ece315..5a6748e42 100644 --- a/tests/testthat/test-glom.R +++ b/tests/testthat/test-glom.R @@ -217,5 +217,11 @@ test_that("glom vectorization", { # truncate twice, initially with drop=FALSE expect_equal(length(trunc(trunc(sp1, 75, 100, drop = FALSE), 90, 100)), 4) + + # no horizons in glom interval, with missing profiles dropped + expect_equal(length(trunc(sp1, 250, 300)), 0) + + # no horizons in glom interval, with missing profiles filled + expect_equal(length(trunc(sp1, 250, 300, drop = FALSE)), 0) })