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) NONE. They should all pass, except for
15   * ALWAYS_JOIN on the outbound endpoint.
16   */
17  public class JmsSingleTransactionSingleServiceNoneConfigurationTestCase extends
18      AbstractJmsSingleTransactionSingleServiceTestCase
19  {
20  
21      @Override
22      protected String getConfigResources()
23      {
24          return "integration/transactions/local/jms-single-tx-single-service-none.xml";
25      }
26  
27      @Test
28      public void testAlwaysJoin() throws Exception
29      {
30          scenarioCommit.setInputDestinationName(JMS_QUEUE_INPUT_CONF_D);
31          scenarioRollback.setInputDestinationName(JMS_QUEUE_INPUT_CONF_D);
32          scenarioNotReceive.setInputDestinationName(JMS_QUEUE_INPUT_CONF_D);
33          scenarioCommit.setOutputDestinationName(JMS_QUEUE_OUTPUT_CONF_D);
34          scenarioRollback.setOutputDestinationName(JMS_QUEUE_OUTPUT_CONF_D);
35          scenarioNotReceive.setOutputDestinationName(JMS_QUEUE_OUTPUT_CONF_D);
36  
37          runTransactionFail("testAlwaysJoin");
38      }
39  }