activemq-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From clebertsuco...@apache.org
Subject activemq-artemis git commit: NO-JIRA: trivial test fix after sync changes
Date Thu, 25 May 2017 21:17:27 GMT
Repository: activemq-artemis
Updated Branches:
  refs/heads/master 36c0b3daf -> 28a60bcdf


NO-JIRA: trivial test fix after sync changes


Project: http://git-wip-us.apache.org/repos/asf/activemq-artemis/repo
Commit: http://git-wip-us.apache.org/repos/asf/activemq-artemis/commit/28a60bcd
Tree: http://git-wip-us.apache.org/repos/asf/activemq-artemis/tree/28a60bcd
Diff: http://git-wip-us.apache.org/repos/asf/activemq-artemis/diff/28a60bcd

Branch: refs/heads/master
Commit: 28a60bcdf74076cd184d8de9f8901015cbeb965a
Parents: 36c0b3d
Author: Clebert Suconic <clebertsuconic@apache.org>
Authored: Thu May 25 17:15:34 2017 -0400
Committer: Clebert Suconic <clebertsuconic@apache.org>
Committed: Thu May 25 17:16:31 2017 -0400

----------------------------------------------------------------------
 .../artemis/tests/integration/client/RoutingTest.java       | 9 +++++----
 1 file changed, 5 insertions(+), 4 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/28a60bcd/tests/integration-tests/src/test/java/org/apache/activemq/artemis/tests/integration/client/RoutingTest.java
----------------------------------------------------------------------
diff --git a/tests/integration-tests/src/test/java/org/apache/activemq/artemis/tests/integration/client/RoutingTest.java
b/tests/integration-tests/src/test/java/org/apache/activemq/artemis/tests/integration/client/RoutingTest.java
index 9d66b61..7877a7f 100644
--- a/tests/integration-tests/src/test/java/org/apache/activemq/artemis/tests/integration/client/RoutingTest.java
+++ b/tests/integration-tests/src/test/java/org/apache/activemq/artemis/tests/integration/client/RoutingTest.java
@@ -29,6 +29,7 @@ import org.apache.activemq.artemis.api.core.client.ServerLocator;
 import org.apache.activemq.artemis.core.server.ActiveMQServer;
 import org.apache.activemq.artemis.api.core.RoutingType;
 import org.apache.activemq.artemis.tests.util.ActiveMQTestBase;
+import org.apache.activemq.artemis.tests.util.Wait;
 import org.junit.Assert;
 import org.junit.Before;
 import org.junit.Test;
@@ -238,8 +239,8 @@ public class RoutingTest extends ActiveMQTestBase {
       message.setRoutingType(RoutingType.ANYCAST);
       p.send(message);
       sendSession.close();
-      assertEquals(1, server.locateQueue(queueA).getMessageCount() + server.locateQueue(queueB).getMessageCount());
-      assertEquals(0, server.locateQueue(queueC).getMessageCount());
+      assertTrue(Wait.waitFor(() -> server.locateQueue(queueA).getMessageCount() + server.locateQueue(queueB).getMessageCount()
== 1));
+      assertTrue(Wait.waitFor(() -> server.locateQueue(queueC).getMessageCount() == 0));
    }
 
    @Test
@@ -257,8 +258,8 @@ public class RoutingTest extends ActiveMQTestBase {
       message.setRoutingType(RoutingType.MULTICAST);
       p.send(message);
       sendSession.close();
-      assertEquals(0, server.locateQueue(queueA).getMessageCount());
-      assertEquals(2, server.locateQueue(queueB).getMessageCount() + server.locateQueue(queueC).getMessageCount());
+      assertTrue(Wait.waitFor(() -> server.locateQueue(queueA).getMessageCount() == 0));
+      assertTrue(Wait.waitFor(() -> server.locateQueue(queueB).getMessageCount() + server.locateQueue(queueC).getMessageCount()
== 2));
    }
 
    @Test


Mime
View raw message