From b3488f035af01627e2c5ea8bee06b7af7202636e Mon Sep 17 00:00:00 2001 From: Johannes Ranke Date: Wed, 9 Dec 2020 14:43:40 +0100 Subject: And more --- tests/testthat/test_f_time_norm.R | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'tests/testthat/test_f_time_norm.R') diff --git a/tests/testthat/test_f_time_norm.R b/tests/testthat/test_f_time_norm.R index 790cce8b..f9aba58a 100644 --- a/tests/testthat/test_f_time_norm.R +++ b/tests/testthat/test_f_time_norm.R @@ -4,3 +4,8 @@ test_that("Simple temperature and moisture normalisation works", { expect_equal(round(f_time_norm_focus(25, 20, 25), 2), 1.37) }) +test_that("Time step normalisation for a dataset works", { + expect_output(f_time_norm_focus(D24_2014, study_moisture_ref_source = "focus", f_na = 1), + "was set to") + expect_equal(round(D24_2014$f_time_norm, 3), c(1.606, 0.712, 0.716, 0.716, 0.898)) +}) -- cgit v1.2.1