You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@activemq.apache.org by cl...@apache.org on 2016/05/05 13:56:23 UTC

[2/2] activemq-artemis git commit: Fix InterceptorTest

Fix InterceptorTest


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

Branch: refs/heads/master
Commit: ad24c58c646b43e3f8e31d13c61ebb07aee3c397
Parents: 28daa6f
Author: jbertram <jb...@apache.org>
Authored: Wed May 4 21:25:43 2016 -0500
Committer: Clebert Suconic <cl...@apache.org>
Committed: Thu May 5 09:55:50 2016 -0400

----------------------------------------------------------------------
 .../tests/integration/interceptors/InterceptorTest.java       | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/ad24c58c/tests/integration-tests/src/test/java/org/apache/activemq/artemis/tests/integration/interceptors/InterceptorTest.java
----------------------------------------------------------------------
diff --git a/tests/integration-tests/src/test/java/org/apache/activemq/artemis/tests/integration/interceptors/InterceptorTest.java b/tests/integration-tests/src/test/java/org/apache/activemq/artemis/tests/integration/interceptors/InterceptorTest.java
index a7a1fd6..cffbed5 100644
--- a/tests/integration-tests/src/test/java/org/apache/activemq/artemis/tests/integration/interceptors/InterceptorTest.java
+++ b/tests/integration-tests/src/test/java/org/apache/activemq/artemis/tests/integration/interceptors/InterceptorTest.java
@@ -51,6 +51,7 @@ import org.apache.activemq.artemis.core.protocol.core.impl.wireformat.SessionSen
 import org.apache.activemq.artemis.core.server.ActiveMQServer;
 import org.apache.activemq.artemis.core.server.ServerMessage;
 import org.apache.activemq.artemis.jms.client.ActiveMQConnectionFactory;
+import org.apache.activemq.artemis.jms.client.ActiveMQDestination;
 import org.apache.activemq.artemis.spi.core.protocol.RemotingConnection;
 import org.apache.activemq.artemis.spi.core.security.ActiveMQJAASSecurityManager;
 import org.apache.activemq.artemis.tests.util.ActiveMQTestBase;
@@ -64,6 +65,8 @@ public class InterceptorTest extends ActiveMQTestBase {
 
    private final SimpleString QUEUE = new SimpleString("InterceptorTestQueue");
 
+   private final SimpleString JMS_QUEUE = SimpleString.toSimpleString(ActiveMQDestination.JMS_QUEUE_ADDRESS_PREFIX + QUEUE.toString());
+
    private ServerLocator locator;
 
    @Override
@@ -1056,6 +1059,8 @@ public class InterceptorTest extends ActiveMQTestBase {
    public void testInterceptorOnURI() throws Exception {
       locator.close();
 
+      server.createQueue(JMS_QUEUE, JMS_QUEUE, null, true, false);
+
       String uri = "tcp://localhost:61616?incomingInterceptorList=" + Incoming.class.getCanonicalName() + "&outgoingInterceptorList=" + Outgoing.class.getName();
 
       System.out.println(uri);
@@ -1084,7 +1089,7 @@ public class InterceptorTest extends ActiveMQTestBase {
       MessageConsumer consumer = session.createConsumer(session.createQueue(QUEUE.toString()));
 
       TextMessage msg = (TextMessage) consumer.receive(5000);
-      Assert.assertNotNull(consumer);
+      Assert.assertNotNull(msg);
 
       Assert.assertEquals("HelloMessage", msg.getText());