Remove TimeMap( start_time ) constructor

This commit is contained in:
Joakim Hove
2020-01-22 16:56:42 +01:00
parent 63e99fb807
commit fc9958bb0c
5 changed files with 5 additions and 17 deletions
+3 -3
View File
@@ -43,14 +43,14 @@ Opm::TimeMap make_timemap(int num) {
BOOST_AUTO_TEST_CASE(CreateDynamicTest) {
const std::time_t startDate = Opm::TimeMap::mkdate(2010, 1, 1);
Opm::TimeMap timeMap{ startDate };
Opm::TimeMap timeMap({ startDate });
Opm::DynamicState<double> state(timeMap , 9.99);
}
BOOST_AUTO_TEST_CASE(DynamicStateGetOutOfRangeThrows) {
const std::time_t startDate = Opm::TimeMap::mkdate(2010, 1, 1);
Opm::TimeMap timeMap{ startDate };
Opm::TimeMap timeMap({ startDate });
Opm::DynamicState<double> state(timeMap , 9.99);
BOOST_CHECK_THROW( state.get(1) , std::out_of_range );
}
@@ -58,7 +58,7 @@ BOOST_AUTO_TEST_CASE(DynamicStateGetOutOfRangeThrows) {
BOOST_AUTO_TEST_CASE(DynamicStateGetDefault) {
const std::time_t startDate = Opm::TimeMap::mkdate(2010, 1, 1);
Opm::TimeMap timeMap{ startDate };
Opm::TimeMap timeMap( { startDate } );
Opm::DynamicState<int> state(timeMap , 137);
BOOST_CHECK_EQUAL( 137 , state.get(0));
BOOST_CHECK_EQUAL( 137 , state.back() );