mirror of
https://github.com/XRPLF/clio.git
synced 2025-11-28 23:55:52 +00:00
@@ -35,9 +35,9 @@ using namespace testing;
|
||||
|
||||
namespace {
|
||||
|
||||
constexpr auto SEQ = 30;
|
||||
constexpr auto kSEQ = 30;
|
||||
|
||||
std::vector<ripple::uint256> const ACCOUNTROOTS = {
|
||||
std::vector<ripple::uint256> const kACCOUNT_ROOTS = {
|
||||
ripple::uint256{"05E1EAC2574BE082B00B16F907CE32E6058DEB8F9E81CF34A00E80A5D71FA4FE"},
|
||||
ripple::uint256{"110872C7196EE6EF7032952F1852B11BB461A96FF2D7E06A8003B4BB30FD130B"},
|
||||
ripple::uint256{"3B3A84E850C724E914293271785A31D0BFC8B9DD1B6332E527B149AD72E80E18"},
|
||||
@@ -56,14 +56,14 @@ TEST_F(CursorFromAccountProviderTests, EnoughAccountRoots)
|
||||
{
|
||||
auto const numCursors = 9;
|
||||
auto const pageSize = 100;
|
||||
auto const provider = etl::impl::CursorFromAccountProvider{backend, numCursors, pageSize};
|
||||
auto const provider = etl::impl::CursorFromAccountProvider{backend_, numCursors, pageSize};
|
||||
|
||||
ON_CALL(*backend, fetchAccountRoots(numCursors, _, SEQ, _)).WillByDefault(Return(ACCOUNTROOTS));
|
||||
EXPECT_CALL(*backend, fetchAccountRoots(_, _, _, _)).Times(1);
|
||||
ON_CALL(*backend_, fetchAccountRoots(numCursors, _, kSEQ, _)).WillByDefault(Return(kACCOUNT_ROOTS));
|
||||
EXPECT_CALL(*backend_, fetchAccountRoots(_, _, _, _)).Times(1);
|
||||
|
||||
auto const cursors = provider.getCursors(SEQ);
|
||||
auto const cursors = provider.getCursors(kSEQ);
|
||||
ASSERT_EQ(cursors.size(), numCursors + 1);
|
||||
|
||||
EXPECT_EQ(cursors.front().start, firstKey);
|
||||
EXPECT_EQ(cursors.back().end, lastKey);
|
||||
EXPECT_EQ(cursors.front().start, kFIRST_KEY);
|
||||
EXPECT_EQ(cursors.back().end, kLAST_KEY);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user