Skip to content

Commit f4a6d22

Browse files
committed
Fix CI failure in testPriorityMessagesWithJmsBrowser
1 parent ee00221 commit f4a6d22

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

activemq-unit-tests/src/test/java/org/apache/activemq/usecases/QueueZeroPrefetchLazyDispatchPriorityTest.java

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -203,6 +203,10 @@ public void testPriorityMessagesWithJmsBrowser() throws Exception {
203203
final ArrayList<Message> consumeList = consumeMessages("TestQ");
204204
LOG.info("Consumed list {}", consumeList.size());
205205

206+
// wait until remaining messages are actually consumed
207+
assertTrue("Remaining messages consumed",
208+
Wait.waitFor(() -> consumeList.size() == numToSend - 1, 5000, 100));
209+
206210
// compare lists
207211
// assertEquals("Iteration: " + i
208212
// +", message 1 should be priority high", 5,

0 commit comments

Comments
 (0)