activemq-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From clebertsuco...@apache.org
Subject [activemq-artemis] branch master updated: NO-JIRA Fixing intermittent failure on AutoDeleteJmsDestinationTest
Date Sun, 05 Apr 2020 04:59:08 GMT
This is an automated email from the ASF dual-hosted git repository.

clebertsuconic pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/activemq-artemis.git


The following commit(s) were added to refs/heads/master by this push:
     new ae17fd6  NO-JIRA Fixing intermittent failure on AutoDeleteJmsDestinationTest
ae17fd6 is described below

commit ae17fd6552069c41ab3300ad4767107ade0c614c
Author: Clebert Suconic <clebertsuconic@apache.org>
AuthorDate: Sun Apr 5 00:55:17 2020 -0400

    NO-JIRA Fixing intermittent failure on AutoDeleteJmsDestinationTest
---
 .../tests/integration/client/AutoDeleteJmsDestinationTest.java    | 8 +++++++-
 1 file changed, 7 insertions(+), 1 deletion(-)

diff --git a/tests/integration-tests/src/test/java/org/apache/activemq/artemis/tests/integration/client/AutoDeleteJmsDestinationTest.java
b/tests/integration-tests/src/test/java/org/apache/activemq/artemis/tests/integration/client/AutoDeleteJmsDestinationTest.java
index 0c63e4c..d36d113 100644
--- a/tests/integration-tests/src/test/java/org/apache/activemq/artemis/tests/integration/client/AutoDeleteJmsDestinationTest.java
+++ b/tests/integration-tests/src/test/java/org/apache/activemq/artemis/tests/integration/client/AutoDeleteJmsDestinationTest.java
@@ -28,6 +28,7 @@ import org.apache.activemq.artemis.api.jms.ActiveMQJMSClient;
 import org.apache.activemq.artemis.core.server.Queue;
 import org.apache.activemq.artemis.core.settings.impl.AddressSettings;
 import org.apache.activemq.artemis.tests.util.JMSTestBase;
+import org.apache.activemq.artemis.tests.util.Wait;
 import org.junit.Assert;
 import org.junit.Test;
 
@@ -73,6 +74,9 @@ public class AutoDeleteJmsDestinationTest extends JMSTestBase {
 
       connection.close();
 
+      SimpleString qname = new SimpleString("test");
+      Wait.waitFor(() -> server.getPostOffice().getBinding(qname) == null);
+
       // ensure the queue was removed
       Assert.assertNull(server.getPostOffice().getBinding(new SimpleString("test")));
 
@@ -152,8 +156,10 @@ public class AutoDeleteJmsDestinationTest extends JMSTestBase {
 
       connection.close();
 
+      SimpleString qName = new SimpleString("test");
+      Wait.waitFor(() -> server.locateQueue(qName) == null);
       // ensure the topic was removed
-      Assert.assertNull(server.locateQueue(new SimpleString("test")));
+      Assert.assertNull(server.locateQueue(qName));
 
       // make sure the JMX control was removed for the JMS topic
       assertNull(server.getManagementService().getResource("jtest"));


Mime
View raw message