From fe8368b970b29a279fbceacf8bc9c8b00c440175 Mon Sep 17 00:00:00 2001 From: Ed Hennis Date: Tue, 7 Jul 2026 20:26:55 -0400 Subject: [PATCH] Update test to ensure correct starting conditions --- src/test/app/SHAMapStore_test.cpp | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/src/test/app/SHAMapStore_test.cpp b/src/test/app/SHAMapStore_test.cpp index 6d570bff45..ac810e88f9 100644 --- a/src/test/app/SHAMapStore_test.cpp +++ b/src/test/app/SHAMapStore_test.cpp @@ -634,11 +634,14 @@ public: LedgerIndex minSeq = 2; LedgerIndex maxSeq = env.closed()->header().seq; auto& store = env.app().getSHAMapStore(); - BEAST_EXPECT(store.rendezvous()); LedgerIndex lastRotated = store.getLastRotated(); + while (lastRotated != 3) + { + BEAST_EXPECT(store.rendezvous()); + lastRotated = store.getLastRotated(); + } BEAST_EXPECTS(maxSeq == 3, std::to_string(maxSeq)); BEAST_EXPECTS(lm.getCompleteLedgers() == "2-3", lm.getCompleteLedgers()); - BEAST_EXPECTS(lastRotated == 3, to_string(lastRotated)); BEAST_EXPECT(lm.missingFromCompleteLedgerRange(minSeq, maxSeq) == 0); BEAST_EXPECT(lm.missingFromCompleteLedgerRange(minSeq + 1, maxSeq - 1) == 0); BEAST_EXPECT(lm.missingFromCompleteLedgerRange(minSeq - 1, maxSeq + 1) == 2);