activemq-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From gtu...@apache.org
Subject activemq git commit: sanity check on provider url params for connection factory
Date Fri, 02 Sep 2016 09:39:46 GMT
Repository: activemq
Updated Branches:
  refs/heads/master bb8d32c04 -> 508df5359


sanity check on provider url params for connection factory


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

Branch: refs/heads/master
Commit: 508df5359c1c85b6c3e0bfd3c316a8c3026c9cd5
Parents: bb8d32c
Author: gtully <gary.tully@gmail.com>
Authored: Fri Sep 2 10:37:46 2016 +0100
Committer: gtully <gary.tully@gmail.com>
Committed: Fri Sep 2 10:38:26 2016 +0100

----------------------------------------------------------------------
 .../org/apache/activemq/jndi/XAConnectionFactoryTest.java    | 8 +++++++-
 1 file changed, 7 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/activemq/blob/508df535/activemq-unit-tests/src/test/java/org/apache/activemq/jndi/XAConnectionFactoryTest.java
----------------------------------------------------------------------
diff --git a/activemq-unit-tests/src/test/java/org/apache/activemq/jndi/XAConnectionFactoryTest.java
b/activemq-unit-tests/src/test/java/org/apache/activemq/jndi/XAConnectionFactoryTest.java
index cf7cca1..8c892e6 100755
--- a/activemq-unit-tests/src/test/java/org/apache/activemq/jndi/XAConnectionFactoryTest.java
+++ b/activemq-unit-tests/src/test/java/org/apache/activemq/jndi/XAConnectionFactoryTest.java
@@ -16,17 +16,23 @@
  */
 package org.apache.activemq.jndi;
 
+import org.apache.activemq.ActiveMQXAConnectionFactory;
+
 import javax.jms.XAConnectionFactory;
+import javax.naming.Context;
 import javax.naming.NamingException;
 
 public class XAConnectionFactoryTest extends ActiveMQInitialContextFactoryTest {
     
     public void testConnectionFactoriesIsXA() throws NamingException {
-        assertTrue("connection factory implements XA", context.lookup(getConnectionFactoryLookupName())
instanceof XAConnectionFactory);
+        Object factory = context.lookup(getConnectionFactoryLookupName());
+        assertTrue("connection factory implements XA", factory instanceof XAConnectionFactory);
+        assertTrue("is always sync send", ((ActiveMQXAConnectionFactory)factory).isAlwaysSyncSend());
     }
     
     protected void configureEnvironment() {
         environment.put("xa", "true");
+        environment.put(Context.PROVIDER_URL, "vm://locahost?jms.alwaysSyncSend=true");
         super.configureEnvironment();
     }
 }


Mime
View raw message