Skip to content

Commit fadf8f0

Browse files
author
MarcoFalke
committed
test: Remove confusing and failing system time test
1 parent df82a24 commit fadf8f0

File tree

1 file changed

+2
-6
lines changed

1 file changed

+2
-6
lines changed

src/test/util_tests.cpp

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -582,18 +582,14 @@ BOOST_AUTO_TEST_CASE(util_time_GetTime)
582582
BOOST_CHECK_EQUAL(111000, TicksSinceEpoch<std::chrono::milliseconds>(NodeClock::now()));
583583
BOOST_CHECK_EQUAL(111000000, GetTime<std::chrono::microseconds>().count());
584584
}
585+
SetMockTime(0s);
585586

586-
SetMockTime(0);
587-
// Check that steady time and system time changes after a sleep
587+
// Check that steady time changes after a sleep
588588
const auto steady_ms_0 = Now<SteadyMilliseconds>();
589589
const auto steady_0 = std::chrono::steady_clock::now();
590-
const auto ms_0 = GetTime<std::chrono::milliseconds>();
591-
const auto us_0 = GetTime<std::chrono::microseconds>();
592590
UninterruptibleSleep(1ms);
593591
BOOST_CHECK(steady_ms_0 < Now<SteadyMilliseconds>());
594592
BOOST_CHECK(steady_0 + 1ms <= std::chrono::steady_clock::now());
595-
BOOST_CHECK(ms_0 < GetTime<std::chrono::milliseconds>());
596-
BOOST_CHECK(us_0 < GetTime<std::chrono::microseconds>());
597593
}
598594

599595
BOOST_AUTO_TEST_CASE(test_IsDigit)

0 commit comments

Comments
 (0)