diff --git a/tests/integration-tests/src/test/java/org/apache/activemq/artemis/tests/integration/management/QueueControlTest.java b/tests/integration-tests/src/test/java/org/apache/activemq/artemis/tests/integration/management/QueueControlTest.java index 7ff689793e..3665245800 100644 --- a/tests/integration-tests/src/test/java/org/apache/activemq/artemis/tests/integration/management/QueueControlTest.java +++ b/tests/integration-tests/src/test/java/org/apache/activemq/artemis/tests/integration/management/QueueControlTest.java @@ -478,6 +478,7 @@ public class QueueControlTest extends ManagementTestBase { long beforeSend = System.currentTimeMillis(); ClientProducer producer = session.createProducer(address); producer.send(session.createMessage(false).putStringProperty("x", "valueX").putStringProperty("y", "valueY")); + Wait.assertEquals(1, queueControl::getMessageCount); long firstMessageTimestamp = queueControl.getFirstMessageTimestamp(); assertTrue(beforeSend <= firstMessageTimestamp);