activemq-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From clebertsuconic <...@git.apache.org>
Subject [GitHub] activemq-artemis pull request #1789: ARTEMIS-1619 - Add plugin support for a...
Date Thu, 18 Jan 2018 16:12:30 GMT
Github user clebertsuconic commented on a diff in the pull request:

    https://github.com/apache/activemq-artemis/pull/1789#discussion_r162390192
  
    --- Diff: tests/integration-tests/src/test/java/org/apache/activemq/artemis/tests/integration/plugin/StompPluginTest.java
---
    @@ -127,10 +131,33 @@ public void testSendAndReceive() throws Exception {
                                                    AFTER_CREATE_SESSION, BEFORE_CLOSE_SESSION,
AFTER_CLOSE_SESSION, BEFORE_CREATE_CONSUMER,
                                                    AFTER_CREATE_CONSUMER, BEFORE_CLOSE_CONSUMER,
AFTER_CLOSE_CONSUMER, BEFORE_CREATE_QUEUE, AFTER_CREATE_QUEUE,
                                                    MESSAGE_ACKED, BEFORE_SEND, AFTER_SEND,
BEFORE_MESSAGE_ROUTE, AFTER_MESSAGE_ROUTE, BEFORE_DELIVER,
    -                                               AFTER_DELIVER);
    +                                               AFTER_DELIVER, BEFORE_ADD_ADDRESS, AFTER_ADD_ADDRESS);
    +
    +      } catch (Throwable e) {
    +         fail(e.getMessage());
    +      }
    +
    +   }
    +
    +   @Test
    +   public void testStompAutoCreateAddress() throws Exception {
    +
    +      try {
    +         URI uri = new URI("ws+v12.stomp://localhost:61613");
    +         StompClientConnection newConn = StompClientConnectionFactory.createClientConnection(uri);
    +         newConn.connect(defUser, defPass);
    +
    +         subscribeQueue(newConn, "a-sub", "autoCreated");
    +
    +         // unsub
    +         unsubscribe(newConn, "a-sub");
    +         newConn.disconnect();
    +
    +         verifier.validatePluginMethodsAtLeast(1, BEFORE_ADD_ADDRESS, AFTER_ADD_ADDRESS,
    +               BEFORE_REMOVE_ADDRESS, AFTER_REMOVE_ADDRESS);
     
           } catch (Throwable e) {
    -         e.printStackTrace();
    +         fail(e.getMessage());
    --- End diff --
    
    the printStackTrace is useful when it fails :)
    I have been there.


---

Mime
View raw message