avoid persistence and TCP by default in test cases

git-svn-id: https://svn.apache.org/repos/asf/incubator/activemq/trunk@356521 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
James Strachan 2005-12-13 16:19:37 +00:00
parent 507bb1bbab
commit ecfbe6168d
1 changed files with 10 additions and 1 deletions

View File

@ -38,7 +38,8 @@ import junit.framework.TestCase;
public class EmbeddedBrokerTestSupport extends TestCase {
protected BrokerService broker;
protected String bindAddress = "tcp://localhost:61616";
//protected String bindAddress = "tcp://localhost:61616";
protected String bindAddress = "vm://localhost";
protected ConnectionFactory connectionFactory;
protected boolean useTopic = false;
protected Destination destination;
@ -127,10 +128,18 @@ public class EmbeddedBrokerTestSupport extends TestCase {
*/
protected BrokerService createBroker() throws Exception {
BrokerService answer = new BrokerService();
answer.setPersistent(isPersistent());
answer.addConnector(bindAddress);
return answer;
}
/**
* @return whether or not persistence should be used
*/
protected boolean isPersistent() {
return false;
}
/**
* Factory method to create a new connection
*/