From eff0c83ffa8a4a75d5ab8ed711cacac0521a3558 Mon Sep 17 00:00:00 2001 From: Paul Date: Fri, 8 Dec 2023 23:01:35 +0100 Subject: [PATCH 1/3] full test coverage of timegrid --- test-suite/timegrid.cpp | 35 +++++++++++++++++++++++++++++++++++ 1 file changed, 35 insertions(+) diff --git a/test-suite/timegrid.cpp b/test-suite/timegrid.cpp index be75146aed4..db7e476faa9 100644 --- a/test-suite/timegrid.cpp +++ b/test-suite/timegrid.cpp @@ -56,6 +56,19 @@ BOOST_AUTO_TEST_CASE(testConstructorMandatorySteps) tg.begin(), tg.end(), expected_times.begin(), expected_times.end()); } +BOOST_AUTO_TEST_CASE(testConstructorAdditionalStepsAutomatically) +{ + BOOST_TEST_MESSAGE("Testing TimeGrid construction with time step length determined automatically..."); + + const TimeGrid tg{{0.0, 1.0, 2.0, 4.0}, 0}; + + // Time step length is determined by minimal adjacent distance in given times + const std::vector