activemq-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From martyntay...@apache.org
Subject [1/2] activemq-6 git commit: topic control test fix
Date Thu, 26 Feb 2015 11:09:25 GMT
Repository: activemq-6
Updated Branches:
  refs/heads/master 41b223290 -> 73638a1d2


topic control test fix


Project: http://git-wip-us.apache.org/repos/asf/activemq-6/repo
Commit: http://git-wip-us.apache.org/repos/asf/activemq-6/commit/97e63645
Tree: http://git-wip-us.apache.org/repos/asf/activemq-6/tree/97e63645
Diff: http://git-wip-us.apache.org/repos/asf/activemq-6/diff/97e63645

Branch: refs/heads/master
Commit: 97e63645d3ba9932d89fe61dc4bfaa9a5563dcff
Parents: 41b2232
Author: Andy Taylor <andytaylor@apache.org>
Authored: Thu Feb 26 10:25:59 2015 +0000
Committer: Andy Taylor <andytaylor@apache.org>
Committed: Thu Feb 26 11:06:36 2015 +0000

----------------------------------------------------------------------
 .../jms/server/management/TopicControlTest.java        | 13 +++++++++----
 1 file changed, 9 insertions(+), 4 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/activemq-6/blob/97e63645/tests/integration-tests/src/test/java/org/apache/activemq/tests/integration/jms/server/management/TopicControlTest.java
----------------------------------------------------------------------
diff --git a/tests/integration-tests/src/test/java/org/apache/activemq/tests/integration/jms/server/management/TopicControlTest.java
b/tests/integration-tests/src/test/java/org/apache/activemq/tests/integration/jms/server/management/TopicControlTest.java
index 6298368..2ca7133 100644
--- a/tests/integration-tests/src/test/java/org/apache/activemq/tests/integration/jms/server/management/TopicControlTest.java
+++ b/tests/integration-tests/src/test/java/org/apache/activemq/tests/integration/jms/server/management/TopicControlTest.java
@@ -26,6 +26,7 @@ import javax.jms.TopicSubscriber;
 import javax.management.Notification;
 
 import java.util.ArrayList;
+import java.util.Arrays;
 import java.util.List;
 import java.util.Map;
 
@@ -194,10 +195,14 @@ public class TopicControlTest extends ManagementTestBase
       String jsonString = topicControl.listDurableSubscriptionsAsJSON();
       SubscriptionInfo[] infos = SubscriptionInfo.from(jsonString);
       Assert.assertEquals(2, infos.length);
-      Assert.assertEquals(clientID, infos[0].getClientID());
-      Assert.assertEquals(subscriptionName, infos[0].getName());
-      Assert.assertEquals(clientID + "2", infos[1].getClientID());
-      Assert.assertEquals(subscriptionName + "2", infos[1].getName());
+      List<String> expectedClientIds = Arrays.asList(clientID, clientID + "2");
+      List<String> expectedSubscriptionNames = Arrays.asList(subscriptionName, subscriptionName
+ "2");
+
+      Assert.assertTrue(expectedClientIds.contains(infos[0].getClientID()));
+      Assert.assertTrue(expectedSubscriptionNames.contains(infos[0].getName()));
+
+      Assert.assertTrue(expectedClientIds.contains(infos[1].getClientID()));
+      Assert.assertTrue(expectedSubscriptionNames.contains(infos[1].getName()));
 
       jsonString = topicControl.listNonDurableSubscriptionsAsJSON();
       infos = SubscriptionInfo.from(jsonString);


Mime
View raw message