Skip to content

Commit 910367e

Browse files
committed
improve tests
1 parent 4a86cf9 commit 910367e

1 file changed

Lines changed: 3 additions & 2 deletions

File tree

tests/ReaderTest.cc

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,8 +24,10 @@
2424

2525
#include <atomic>
2626
#include <chrono>
27+
#include <cstdint>
2728
#include <functional>
2829
#include <future>
30+
#include <limits>
2931
#include <set>
3032
#include <string>
3133
#include <thread>
@@ -38,7 +40,6 @@
3840
#include "lib/Latch.h"
3941
#include "lib/LogUtils.h"
4042
#include "lib/ReaderImpl.h"
41-
#include "lib/TimeUtils.h"
4243
DECLARE_LOG_OBJECT()
4344

4445
using namespace pulsar;
@@ -990,7 +991,7 @@ TEST_P(ReaderSeekTest, testSeekToEndByTimestamp) {
990991
ASSERT_EQ(ResultOk, client.createReader(topic, MessageId::earliest(), readerConf, reader));
991992

992993
ASSERT_EQ(ResultOk, producer.send(MessageBuilder().setContent("msg").build()));
993-
auto now = TimeUtils::currentTimeMillis() + 1000;
994+
auto now = std::numeric_limits<uint64_t>::max();
994995
ASSERT_EQ(ResultOk, reader.seek(now));
995996

996997
bool hasMessageAvailable;

0 commit comments

Comments
 (0)