You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pulsar.apache.org by GitBox <gi...@apache.org> on 2023/01/04 03:19:53 UTC

[GitHub] [pulsar] coderzc commented on a diff in pull request #19124: [fix][broker][PIP-195] fix cursor skip read

coderzc commented on code in PR #19124:
URL: https://github.com/apache/pulsar/pull/19124#discussion_r1061107452


##########
managed-ledger/src/test/java/org/apache/bookkeeper/mledger/impl/ManagedCursorTest.java:
##########
@@ -4275,7 +4275,14 @@ public void testReadEntriesWithFilterOut() throws ManagedLedgerException, Interr
         cursor.asyncReadEntriesWithSkipOrWait(sendNumber, new ReadEntriesCallback() {
             @Override
             public void readEntriesComplete(List<Entry> entries, Object ctx) {
-                completableFuture.complete(entries.size());
+                try {
+                    entries.forEach(entry -> {
+                        assertNotEquals(entry.getEntryId() % 2, 0);

Review Comment:
   > It should be `assertEquals(entry.getEntryId() % 2, 0);`
   
   It should be `assertSame(entry.getEntryId() % 2, 0);`



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org