activemq-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From gtu...@apache.org
Subject svn commit: r1352487 - /activemq/trunk/activemq-core/src/test/java/org/apache/activemq/bugs/AMQ3014Test.java
Date Thu, 21 Jun 2012 10:11:23 GMT
Author: gtully
Date: Thu Jun 21 10:11:22 2012
New Revision: 1352487

URL: http://svn.apache.org/viewvc?rev=1352487&view=rev
Log:
AMQ-3014 remove hardcoded port 50000

Modified:
    activemq/trunk/activemq-core/src/test/java/org/apache/activemq/bugs/AMQ3014Test.java

Modified: activemq/trunk/activemq-core/src/test/java/org/apache/activemq/bugs/AMQ3014Test.java
URL: http://svn.apache.org/viewvc/activemq/trunk/activemq-core/src/test/java/org/apache/activemq/bugs/AMQ3014Test.java?rev=1352487&r1=1352486&r2=1352487&view=diff
==============================================================================
--- activemq/trunk/activemq-core/src/test/java/org/apache/activemq/bugs/AMQ3014Test.java (original)
+++ activemq/trunk/activemq-core/src/test/java/org/apache/activemq/bugs/AMQ3014Test.java Thu
Jun 21 10:11:22 2012
@@ -48,7 +48,7 @@ import org.junit.Test;
  */
 public class AMQ3014Test {
     // Change this URL to be an unused port.
-    private static final String REMOTE_BROKER_URL = "tcp://localhost:50000";
+    private static final String BROKER_URL = "tcp://localhost:0";
 
     private List<BrokerInfo> remoteBrokerInfos = Collections
             .synchronizedList(new ArrayList<BrokerInfo>());
@@ -111,7 +111,7 @@ public class AMQ3014Test {
         remoteBroker.setBrokerName("remoteBroker");
         remoteBroker.setPersistent(false);
         remoteBroker.setUseJmx(false);
-        remoteBroker.addConnector(REMOTE_BROKER_URL);
+        remoteBroker.addConnector(BROKER_URL);
         remoteBroker.setSchedulerSupport(false);
     }
 
@@ -150,7 +150,7 @@ public class AMQ3014Test {
         // to the remote broker.
         DiscoveryNetworkConnector dnc = new DiscoveryNetworkConnector();
         SimpleDiscoveryAgent da = new SimpleDiscoveryAgent();
-        da.setServices(REMOTE_BROKER_URL);
+        da.setServices(remoteBroker.getTransportConnectors().get(0).getPublishableConnectString());
         dnc.setDiscoveryAgent(da);
         localBroker.addNetworkConnector(dnc);
 



Mime
View raw message