You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@camel.apache.org by bv...@apache.org on 2012/08/18 11:59:14 UTC
svn commit: r1374539 -
/camel/trunk/tests/camel-itest/src/test/java/org/apache/camel/itest/jms/JMSTransactionIsTransactedRedeliveredTest.java
Author: bvahdat
Date: Sat Aug 18 09:59:14 2012
New Revision: 1374539
URL: http://svn.apache.org/viewvc?rev=1374539&view=rev
Log:
CAMEL-5508: Fixed the broken itest.
Modified:
camel/trunk/tests/camel-itest/src/test/java/org/apache/camel/itest/jms/JMSTransactionIsTransactedRedeliveredTest.java
Modified: camel/trunk/tests/camel-itest/src/test/java/org/apache/camel/itest/jms/JMSTransactionIsTransactedRedeliveredTest.java
URL: http://svn.apache.org/viewvc/camel/trunk/tests/camel-itest/src/test/java/org/apache/camel/itest/jms/JMSTransactionIsTransactedRedeliveredTest.java?rev=1374539&r1=1374538&r2=1374539&view=diff
==============================================================================
--- camel/trunk/tests/camel-itest/src/test/java/org/apache/camel/itest/jms/JMSTransactionIsTransactedRedeliveredTest.java (original)
+++ camel/trunk/tests/camel-itest/src/test/java/org/apache/camel/itest/jms/JMSTransactionIsTransactedRedeliveredTest.java Sat Aug 18 09:59:14 2012
@@ -16,10 +16,12 @@
*/
package org.apache.camel.itest.jms;
+import org.apache.camel.CamelContext;
import org.apache.camel.Exchange;
import org.apache.camel.Processor;
import org.apache.camel.builder.AdviceWithRouteBuilder;
import org.apache.camel.component.mock.MockEndpoint;
+import org.apache.camel.component.properties.PropertiesComponent;
import org.apache.camel.test.AvailablePortFinder;
import org.apache.camel.test.junit4.CamelSpringTestSupport;
import org.junit.Test;
@@ -49,6 +51,15 @@ public class JMSTransactionIsTransactedR
return true;
}
+ @Override
+ protected CamelContext createCamelContext() throws Exception {
+ // as we make use of placeholders for the Jetty port we should add PropertiesComponent beforehand
+ // so that the port can properly be resolved
+ CamelContext context = super.createCamelContext();
+ context.addComponent("properties", new PropertiesComponent());
+ return context;
+ }
+
@Test
public void testTransactionSuccess() throws Exception {
context.getRouteDefinitions().get(0).adviceWith(context, new AdviceWithRouteBuilder() {