From 974a80002a5b5bb603c92a1111ae31b480af6115 Mon Sep 17 00:00:00 2001 From: brusdev Date: Tue, 17 Mar 2020 20:26:40 +0100 Subject: [PATCH] NO-JIRA Fixing GeneralInteropTest stability --- .../integration/openwire/interop/GeneralInteropTest.java | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/tests/integration-tests/src/test/java/org/apache/activemq/artemis/tests/integration/openwire/interop/GeneralInteropTest.java b/tests/integration-tests/src/test/java/org/apache/activemq/artemis/tests/integration/openwire/interop/GeneralInteropTest.java index 63721109da..66d7247afb 100644 --- a/tests/integration-tests/src/test/java/org/apache/activemq/artemis/tests/integration/openwire/interop/GeneralInteropTest.java +++ b/tests/integration-tests/src/test/java/org/apache/activemq/artemis/tests/integration/openwire/interop/GeneralInteropTest.java @@ -235,7 +235,8 @@ public class GeneralInteropTest extends BasicOpenWireTest { } } - Wait.assertEquals(0, queueControl::getDeliveringCount); + Wait.assertEquals(1L, () -> queueControl.getMessagesAcknowledged(), 3000, 100); + Wait.assertEquals(prefetchSize, () -> queueControl.getDeliveringCount(), 3000, 100); message = consumer.receive(5000); assertNotNull(message); @@ -243,7 +244,7 @@ public class GeneralInteropTest extends BasicOpenWireTest { assertEquals(text + 1, ((TextMessage)message).getText()); message.acknowledge(); - Wait.assertEquals(1L, () -> queueControl.getMessagesAcknowledged(), 3000, 100); + Wait.assertEquals(2L, () -> queueControl.getMessagesAcknowledged(), 3000, 100); Wait.assertEquals(prefetchSize, () -> queueControl.getDeliveringCount(), 30000, 100); } finally { connection.close();