View Javadoc
1   /*
2    * Copyright (c) MuleSoft, Inc.  All rights reserved.  http://www.mulesoft.com
3    * The software in this package is published under the terms of the CPAL v1.0
4    * license, a copy of which has been included with this distribution in the
5    * LICENSE.txt file.
6    */
7   package org.mule.transport.jms.integration.transactions.local;
8   
9   import org.mule.transport.jms.integration.AbstractJmsSingleTransactionSingleServiceTestCase;
10  
11  import org.junit.Test;
12  
13  /**
14   * Test all combinations of (inbound) JOIN_IF_POSSIBLE. They should all pass, except
15   * for ALWAYS_JOIN on the outbound endpoint, since no transaction should be created by JOIN_IF_POSSIBLE.
16   */
17  public class JmsSingleTransactionSingleServiceJoinIfPossibleConfigurationTestCase extends
18      AbstractJmsSingleTransactionSingleServiceTestCase
19  {
20  
21      @Override
22      protected String getConfigResources()
23      {
24          return "integration/transactions/local/jms-single-tx-single-service-join-if-possible.xml";
25      }
26  
27      @Test
28      public void testAlwaysJoin() throws Exception
29      {
30          // no-op, investigating why expected failure doesn't occur
31          /*
32          scenarioCommit.setInputDestinationName(JMS_QUEUE_INPUT_CONF_D);
33          scenarioRollback.setInputDestinationName(JMS_QUEUE_INPUT_CONF_D);
34          scenarioNotReceive.setInputDestinationName(JMS_QUEUE_INPUT_CONF_D);
35          scenarioCommit.setOutputDestinationName(JMS_QUEUE_OUTPUT_CONF_D);
36          scenarioRollback.setOutputDestinationName(JMS_QUEUE_OUTPUT_CONF_D);
37          scenarioNotReceive.setOutputDestinationName(JMS_QUEUE_OUTPUT_CONF_D);
38  
39          runTransactionFail("testAlwaysJoin");
40          */
41      }
42  }