diff options
author | Henning Baldersheim <balder@yahoo-inc.com> | 2019-11-19 23:22:55 +0000 |
---|---|---|
committer | Henning Baldersheim <balder@yahoo-inc.com> | 2019-11-20 21:55:01 +0000 |
commit | cf3b20dba22718b533eac6854cde86b6538958af (patch) | |
tree | 9a0e795cd74d2721140c48012f794298dfef7420 /searchlib/src/tests/aggregator | |
parent | 64b7c822099d7cda921699e380c4d95608a1ab00 (diff) |
FastOS_Time -> std::chrono.
Diffstat (limited to 'searchlib/src/tests/aggregator')
-rw-r--r-- | searchlib/src/tests/aggregator/perdocexpr.cpp | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/searchlib/src/tests/aggregator/perdocexpr.cpp b/searchlib/src/tests/aggregator/perdocexpr.cpp index b8584980cf9..c078282c442 100644 --- a/searchlib/src/tests/aggregator/perdocexpr.cpp +++ b/searchlib/src/tests/aggregator/perdocexpr.cpp @@ -694,10 +694,9 @@ TEST("testDebugFunction") { DebugWaitFunctionNode n(std::move(add), 1.3, false); n.prepare(false); - FastOS_Time time; - time.SetNow(); + fastos::StopWatch timer; n.execute(); - EXPECT_TRUE(time.MilliSecsToNow() > 1000.0); + EXPECT_TRUE(timer.elapsed().ms() > 1000.0); EXPECT_EQUAL(static_cast<const Int64ResultNode &>(n.getResult()).get(), 7); } { @@ -707,10 +706,9 @@ TEST("testDebugFunction") { DebugWaitFunctionNode n(std::move(add), 1.3, true); n.prepare(false); - FastOS_Time time; - time.SetNow(); + fastos::StopWatch timer; n.execute(); - EXPECT_TRUE(time.MilliSecsToNow() > 1000.0); + EXPECT_TRUE(timer.elapsed().ms() > 1000.0); EXPECT_EQUAL(static_cast<const Int64ResultNode &>(n.getResult()).get(), 7); } } |