Author: clebert.suconic(a)jboss.com
Date: 2011-09-21 15:59:57 -0400 (Wed, 21 Sep 2011)
New Revision: 11394
Modified:
branches/Branch_2_2_EAP/tests/src/org/hornetq/tests/integration/jms/server/management/TopicControlUsingJMSTest.java
Log:
fixing a test
Modified:
branches/Branch_2_2_EAP/tests/src/org/hornetq/tests/integration/jms/server/management/TopicControlUsingJMSTest.java
===================================================================
---
branches/Branch_2_2_EAP/tests/src/org/hornetq/tests/integration/jms/server/management/TopicControlUsingJMSTest.java 2011-09-21
19:44:31 UTC (rev 11393)
+++
branches/Branch_2_2_EAP/tests/src/org/hornetq/tests/integration/jms/server/management/TopicControlUsingJMSTest.java 2011-09-21
19:59:57 UTC (rev 11394)
@@ -13,7 +13,6 @@
package org.hornetq.tests.integration.jms.server.management;
-import static junit.framework.Assert.assertEquals;
import static org.hornetq.tests.util.RandomUtil.randomString;
import javax.jms.Connection;
@@ -30,9 +29,7 @@
import org.hornetq.api.core.management.ResourceNames;
import org.hornetq.api.jms.HornetQJMSClient;
import org.hornetq.api.jms.JMSFactoryType;
-import org.hornetq.api.jms.management.TopicControl;
import org.hornetq.core.config.Configuration;
-import org.hornetq.core.config.impl.ConfigurationImpl;
import org.hornetq.core.remoting.impl.invm.InVMConnectorFactory;
import org.hornetq.core.server.HornetQServer;
import org.hornetq.core.server.HornetQServers;
@@ -96,7 +93,7 @@
Connection connection_2 =
JMSUtil.createConnection(InVMConnectorFactory.class.getName());
JMSUtil.createDurableSubscriber(connection_2, topic, clientID, subscriptionName);
Connection connection_3 =
JMSUtil.createConnection(InVMConnectorFactory.class.getName());
- JMSUtil.createDurableSubscriber(connection_3, topic, clientID, subscriptionName +
"2");
+ JMSUtil.createDurableSubscriber(connection_3, topic, clientID + "2",
subscriptionName + "2");
Assert.assertEquals(3,
proxy.retrieveAttributeValue("subscriptionCount"));
Assert.assertEquals(1,
proxy.retrieveAttributeValue("nonDurableSubscriptionCount"));
@@ -115,7 +112,7 @@
Connection connection_2 =
JMSUtil.createConnection(InVMConnectorFactory.class.getName());
JMSUtil.createDurableSubscriber(connection_2, topic, clientID, subscriptionName);
Connection connection_3 =
JMSUtil.createConnection(InVMConnectorFactory.class.getName());
- JMSUtil.createDurableSubscriber(connection_3, topic, clientID, subscriptionName +
"2");
+ JMSUtil.createDurableSubscriber(connection_3, topic, clientID + "2",
subscriptionName + "2");
Assert.assertEquals(0, proxy.retrieveAttributeValue("messageCount"));
Assert.assertEquals(0,
proxy.retrieveAttributeValue("nonDurableMessageCount"));
@@ -140,7 +137,7 @@
Connection connection_2 =
JMSUtil.createConnection(InVMConnectorFactory.class.getName());
JMSUtil.createDurableSubscriber(connection_2, topic, clientID, subscriptionName);
Connection connection_3 =
JMSUtil.createConnection(InVMConnectorFactory.class.getName());
- JMSUtil.createDurableSubscriber(connection_3, topic, clientID, subscriptionName +
"2");
+ JMSUtil.createDurableSubscriber(connection_3, topic, clientID + "2",
subscriptionName + "2");
Assert.assertEquals(3,
((Object[])proxy.invokeOperation("listAllSubscriptions")).length);
Assert.assertEquals(1,
((Object[])proxy.invokeOperation("listNonDurableSubscriptions")).length);
@@ -254,7 +251,7 @@
Connection connection_2 =
JMSUtil.createConnection(InVMConnectorFactory.class.getName());
TopicSubscriber durableSubscriber_2 =
JMSUtil.createDurableSubscriber(connection_2,
topic,
- clientID,
+ clientID +
"2",
subscriptionName + "2");
Assert.assertEquals(2,
proxy.retrieveAttributeValue("subscriptionCount"));
@@ -276,7 +273,7 @@
Connection connection_1 =
JMSUtil.createConnection(InVMConnectorFactory.class.getName());
JMSUtil.createDurableSubscriber(connection_1, topic, clientID, subscriptionName);
Connection connection_2 =
JMSUtil.createConnection(InVMConnectorFactory.class.getName());
- JMSUtil.createDurableSubscriber(connection_2, topic, clientID, subscriptionName +
"2");
+ JMSUtil.createDurableSubscriber(connection_2, topic, clientID + "2",
subscriptionName + "2");
JMSUtil.sendMessages(topic, 3);
@@ -344,7 +341,7 @@
Connection connection_2 =
JMSUtil.createConnection(InVMConnectorFactory.class.getName());
JMSUtil.createDurableSubscriber(connection_2, topic, clientID, subscriptionName);
Connection connection_3 =
JMSUtil.createConnection(InVMConnectorFactory.class.getName());
- JMSUtil.createDurableSubscriber(connection_3, topic, clientID, subscriptionName +
"2");
+ JMSUtil.createDurableSubscriber(connection_3, topic, clientID + "2",
subscriptionName + "2");
assertEquals(0, proxy.retrieveAttributeValue("messagesAdded"));
@@ -370,7 +367,7 @@
Connection connection_3 =
JMSUtil.createConnection(InVMConnectorFactory.class.getName());
MessageConsumer cons_3 = JMSUtil.createDurableSubscriber(connection_3,
topic,
- clientID,
+ clientID + "2",
subscriptionName +
"2",
Session.CLIENT_ACKNOWLEDGE);