added test for copy() method

git-svn-id: https://svn.apache.org/repos/asf/incubator/activemq/trunk@384459 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
James Strachan 2006-03-09 08:25:03 +00:00
parent 46ad8c2d71
commit 346cdc5744
1 changed files with 7 additions and 1 deletions

View File

@ -20,7 +20,6 @@ import java.net.URI;
import java.net.URISyntaxException;
import javax.jms.*;
import javax.jms.JMSException;
import org.apache.activemq.ActiveMQXAConnectionFactory;
import org.apache.activemq.broker.BrokerRegistry;
@ -29,6 +28,13 @@ import org.apache.activemq.broker.TransportConnector;
public class ActiveMQXAConnectionFactoryTest extends CombinationTestSupport {
public void testCopy() throws URISyntaxException, JMSException {
ActiveMQXAConnectionFactory cf = new ActiveMQXAConnectionFactory("vm://localhost?");
ActiveMQConnectionFactory copy = cf.copy();
assertTrue("Should be an ActiveMQXAConnectionFactory", copy instanceof ActiveMQXAConnectionFactory);
}
public void testUseURIToSetOptionsOnConnectionFactory() throws URISyntaxException, JMSException {
ActiveMQXAConnectionFactory cf = new ActiveMQXAConnectionFactory("vm://localhost?jms.useAsyncSend=true");
assertTrue(cf.isUseAsyncSend());