camel-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From davscl...@apache.org
Subject svn commit: r1100567 - in /camel/trunk: components/camel-blueprint/ components/camel-jms/ components/camel-jms/src/test/java/org/apache/camel/component/jms/ components/camel-jms/src/test/java/org/apache/camel/component/jms/async/ components/camel-jms/s...
Date Sat, 07 May 2011 16:49:25 GMT
Author: davsclaus
Date: Sat May  7 16:49:24 2011
New Revision: 1100567

URL: http://svn.apache.org/viewvc?rev=1100567&view=rev
Log:
CAMEL-3032: Do not use test-jar. Make camel-jms unit testing go faster. Remove camel-blueprint-tests.jar and camel-spring-tests.jar from being installed in maven repos

Added:
    camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/async/MyAsyncComponent.java
    camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/async/MyAsyncEndpoint.java
    camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/async/MyAsyncProducer.java
    camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/issues/MyFailureProcessor.java
    camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/remoting/ISay.java
    camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/remoting/SayService.java
Removed:
    camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/issues/JmsIssue170Test.java
    camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/issues/JmsSpringResequencerTest.java
    camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/remoting/RemotingTest.java
Modified:
    camel/trunk/components/camel-blueprint/pom.xml
    camel/trunk/components/camel-jms/pom.xml
    camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/JmsRouteUsingDifferentHeadersTest.java
    camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/config/JmsEndpointWithCustomDestinationTest.java
    camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/issues/JmsRedeliveryWithInitialRedeliveryDelayTest.java
    camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/issues/JmsResequencerTest.java
    camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/issues/TransactionErrorHandlerRedeliveryDelayTest.java
    camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/remoting/JmsRemotingTest.java
    camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/tx/AsyncEndpointJmsTX2Test.java
    camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/tx/AsyncEndpointJmsTXMulticastTest.java
    camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/tx/AsyncEndpointJmsTXRecipientListTest.java
    camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/tx/AsyncEndpointJmsTXRollback2Test.java
    camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/tx/AsyncEndpointJmsTXRollbackTest.java
    camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/tx/AsyncEndpointJmsTXRoutingSlipTest.java
    camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/tx/AsyncEndpointJmsTXTest.java
    camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/tx/AsyncEndpointJmsTXTryCatchFinallyTest.java
    camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/tx/AsyncEndpointJmsTXWireTapTest.java
    camel/trunk/components/camel-jms/src/test/resources/org/apache/camel/component/jms/issues/JmsRedeliveryWithInitialRedeliveryDelayTest-context.xml
    camel/trunk/components/camel-jms/src/test/resources/org/apache/camel/component/jms/remoting/spring.xml
    camel/trunk/components/camel-spring/pom.xml
    camel/trunk/components/camel-spring/src/test/java/org/apache/camel/spring/remoting/SpringRemotingRouteTest.java
    camel/trunk/parent/pom.xml
    camel/trunk/tests/camel-partial-classpath-test/pom.xml
    camel/trunk/tests/camel-partial-classpath-test/src/test/java/org/apache/camel/tests/partialclasspath/RouteTest.java

Modified: camel/trunk/components/camel-blueprint/pom.xml
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-blueprint/pom.xml?rev=1100567&r1=1100566&r2=1100567&view=diff
==============================================================================
--- camel/trunk/components/camel-blueprint/pom.xml (original)
+++ camel/trunk/components/camel-blueprint/pom.xml Sat May  7 16:49:24 2011
@@ -125,10 +125,7 @@
                         <phase>package</phase>
                         <configuration>
                             <tasks>
-                                <echo>Deleting unwanted resources from the test-jar</echo>
-                                <delete file="${project.build.directory}/test-classes/log4j.properties" verbose="true" />
-                                <delete file="${project.build.directory}/test-classes/META-INF/spring/*" verbose="true" />
-
+                                <echo>Including source code from camel-core-xml in the camel-blueprint-sources.ar</echo>
                                 <jar destfile="${project.build.directory}/${project.artifactId}-${project.version}-sources.jar" update="true">
                                   <fileset dir="${basedir}/../camel-core-osgi/src/main/java" includes="**/*" />
                                   <fileset dir="${basedir}/../camel-core-xml/src/main/java" includes="**/*" />

Modified: camel/trunk/components/camel-jms/pom.xml
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-jms/pom.xml?rev=1100567&r1=1100566&r2=1100567&view=diff
==============================================================================
--- camel/trunk/components/camel-jms/pom.xml (original)
+++ camel/trunk/components/camel-jms/pom.xml Sat May  7 16:49:24 2011
@@ -72,31 +72,12 @@
         </dependency>
 
         <!-- testing -->
-        <!--  for JmsIssue170Test -->
-        <dependency>
-            <groupId>org.apache.camel</groupId>
-            <artifactId>camel-core</artifactId>
-            <type>test-jar</type>
-            <scope>test</scope>
-        </dependency>
-        <!-- for JmsRemotingTest and RemotingTest -->
-        <dependency>
-            <groupId>org.apache.camel</groupId>
-            <artifactId>camel-spring</artifactId>
-            <type>test-jar</type>
-            <scope>test</scope>
-        </dependency>
         <dependency>
             <groupId>org.apache.camel</groupId>
             <artifactId>camel-test</artifactId>
             <scope>test</scope>
         </dependency>
         <dependency>
-            <groupId>org.springframework</groupId>
-            <artifactId>spring-test</artifactId>
-            <scope>test</scope>
-        </dependency>
-        <dependency>
             <groupId>javax.annotation</groupId>
             <artifactId>jsr250-api</artifactId>
             <scope>test</scope>

Modified: camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/JmsRouteUsingDifferentHeadersTest.java
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/JmsRouteUsingDifferentHeadersTest.java?rev=1100567&r1=1100566&r2=1100567&view=diff
==============================================================================
--- camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/JmsRouteUsingDifferentHeadersTest.java (original)
+++ camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/JmsRouteUsingDifferentHeadersTest.java Sat May  7 16:49:24 2011
@@ -20,19 +20,20 @@ import java.util.LinkedHashMap;
 import java.util.Map;
 import javax.jms.ConnectionFactory;
 
-import org.apache.activemq.ActiveMQConnectionFactory;
 import org.apache.camel.CamelContext;
-import org.apache.camel.ContextTestSupport;
 import org.apache.camel.builder.RouteBuilder;
 import org.apache.camel.component.mock.MockEndpoint;
+import org.apache.camel.test.junit4.CamelTestSupport;
+import org.junit.Test;
 
 import static org.apache.camel.component.jms.JmsComponent.jmsComponentAutoAcknowledge;
 
 /**
  * @version 
  */
-public class JmsRouteUsingDifferentHeadersTest extends ContextTestSupport {
+public class JmsRouteUsingDifferentHeadersTest extends CamelTestSupport {
 
+    @Test
     public void testUsingDifferentHeaderTypes() throws Exception {
         Map<String, Object> headers = new LinkedHashMap<String, Object>();
         headers.put("a", new Byte("65"));

Added: camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/async/MyAsyncComponent.java
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/async/MyAsyncComponent.java?rev=1100567&view=auto
==============================================================================
--- camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/async/MyAsyncComponent.java (added)
+++ camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/async/MyAsyncComponent.java Sat May  7 16:49:24 2011
@@ -0,0 +1,37 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.camel.component.jms.async;
+
+import java.util.Map;
+
+import org.apache.camel.Endpoint;
+import org.apache.camel.impl.DefaultComponent;
+
+/**
+ *
+ */
+public class MyAsyncComponent extends DefaultComponent {
+
+    @Override
+    protected Endpoint createEndpoint(String uri, String remaining, Map<String, Object> parameters) throws Exception {
+        MyAsyncEndpoint answer = new MyAsyncEndpoint(uri, this);
+        answer.setReply(remaining);
+        setProperties(answer, parameters);
+        return answer;
+    }
+
+}

Added: camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/async/MyAsyncEndpoint.java
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/async/MyAsyncEndpoint.java?rev=1100567&view=auto
==============================================================================
--- camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/async/MyAsyncEndpoint.java (added)
+++ camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/async/MyAsyncEndpoint.java Sat May  7 16:49:24 2011
@@ -0,0 +1,80 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.camel.component.jms.async;
+
+import org.apache.camel.Component;
+import org.apache.camel.Consumer;
+import org.apache.camel.Processor;
+import org.apache.camel.Producer;
+import org.apache.camel.impl.DefaultEndpoint;
+import org.apache.camel.impl.SynchronousDelegateProducer;
+
+/**
+ *
+ */
+public class MyAsyncEndpoint extends DefaultEndpoint {
+
+    private String reply;
+    private long delay = 25;
+    private int failFirstAttempts;
+
+    public MyAsyncEndpoint(String endpointUri, Component component) {
+        super(endpointUri, component);
+    }
+
+    public Producer createProducer() throws Exception {
+        Producer answer = new MyAsyncProducer(this);
+        if (isSynchronous()) {
+            // force it to be synchronously
+            return new SynchronousDelegateProducer(answer);
+        } else {
+            return answer;
+        }
+    }
+
+    public Consumer createConsumer(Processor processor) throws Exception {
+        throw new UnsupportedOperationException("Consumer not supported");
+    }
+
+    public boolean isSingleton() {
+        return false;
+    }
+
+    public String getReply() {
+        return reply;
+    }
+
+    public void setReply(String reply) {
+        this.reply = reply;
+    }
+
+    public long getDelay() {
+        return delay;
+    }
+
+    public void setDelay(long delay) {
+        this.delay = delay;
+    }
+
+    public int getFailFirstAttempts() {
+        return failFirstAttempts;
+    }
+
+    public void setFailFirstAttempts(int failFirstAttempts) {
+        this.failFirstAttempts = failFirstAttempts;
+    }
+}

Added: camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/async/MyAsyncProducer.java
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/async/MyAsyncProducer.java?rev=1100567&view=auto
==============================================================================
--- camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/async/MyAsyncProducer.java (added)
+++ camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/async/MyAsyncProducer.java Sat May  7 16:49:24 2011
@@ -0,0 +1,78 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.camel.component.jms.async;
+
+import java.util.concurrent.Callable;
+import java.util.concurrent.ExecutorService;
+import java.util.concurrent.atomic.AtomicInteger;
+
+import org.apache.camel.AsyncCallback;
+import org.apache.camel.CamelExchangeException;
+import org.apache.camel.Exchange;
+import org.apache.camel.impl.DefaultAsyncProducer;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+/**
+ *
+ */
+public class MyAsyncProducer extends DefaultAsyncProducer {
+
+    private static final Logger LOG = LoggerFactory.getLogger(MyAsyncProducer.class);
+    private final ExecutorService executor;
+    private final AtomicInteger counter = new AtomicInteger();
+
+    public MyAsyncProducer(MyAsyncEndpoint endpoint) {
+        super(endpoint);
+        this.executor = endpoint.getCamelContext().getExecutorServiceStrategy().newCachedThreadPool(this, "MyProducer");
+    }
+
+    public MyAsyncEndpoint getEndpoint() {
+        return (MyAsyncEndpoint) super.getEndpoint();
+    }
+
+    public boolean process(final Exchange exchange, final AsyncCallback callback) {
+        executor.submit(new Callable<Object>() {
+            public Object call() throws Exception {
+
+                LOG.info("Simulating a task which takes " + getEndpoint().getDelay() + " millis to reply");
+                Thread.sleep(getEndpoint().getDelay());
+
+                int count = counter.incrementAndGet();
+                if (getEndpoint().getFailFirstAttempts() >= count) {
+                    LOG.info("Simulating a failure at attempt " + count);
+                    exchange.setException(new CamelExchangeException("Simulated error at attempt " + count, exchange));
+                } else {
+                    String reply = getEndpoint().getReply();
+                    exchange.getOut().setBody(reply);
+                    // propagate headers
+                    exchange.getOut().setHeaders(exchange.getIn().getHeaders());
+                    LOG.info("Setting reply " + reply);
+                }
+
+                LOG.info("Callback done(false)");
+                callback.done(false);
+                return null;
+            }
+        });
+
+        // indicate from this point forward its being routed asynchronously
+        LOG.info("Task submitted, now tell Camel routing engine to that this Exchange is being continued asynchronously");
+        return false;
+    }
+
+}

Modified: camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/config/JmsEndpointWithCustomDestinationTest.java
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/config/JmsEndpointWithCustomDestinationTest.java?rev=1100567&r1=1100566&r2=1100567&view=diff
==============================================================================
--- camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/config/JmsEndpointWithCustomDestinationTest.java (original)
+++ camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/config/JmsEndpointWithCustomDestinationTest.java Sat May  7 16:49:24 2011
@@ -17,43 +17,35 @@
 package org.apache.camel.component.jms.config;
 
 import org.apache.activemq.command.ActiveMQQueue;
-import org.apache.camel.EndpointInject;
-import org.apache.camel.Produce;
-import org.apache.camel.ProducerTemplate;
-import org.apache.camel.component.mock.MockEndpoint;
+import org.apache.camel.test.junit4.CamelSpringTestSupport;
 import org.junit.Test;
-import org.springframework.beans.factory.annotation.Autowired;
-import org.springframework.test.context.ContextConfiguration;
-import org.springframework.test.context.junit4.AbstractJUnit4SpringContextTests;
-
-import static org.junit.Assert.assertEquals;
-import static org.junit.Assert.assertNotNull;
+import org.springframework.context.support.AbstractApplicationContext;
+import org.springframework.context.support.ClassPathXmlApplicationContext;
 
 
 /**
  * @version 
  */
-@ContextConfiguration
-public class JmsEndpointWithCustomDestinationTest extends AbstractJUnit4SpringContextTests {
-    @Produce(uri = "direct:start")
-    protected ProducerTemplate template;
-    @EndpointInject(uri = "mock:result")
-    protected MockEndpoint result;
-    @Autowired
-    protected ActiveMQQueue jmsQueue;
+public class JmsEndpointWithCustomDestinationTest extends CamelSpringTestSupport {
 
     private Object expectedBody = "<hello>world!</hello>";
 
+    @Override
+    protected AbstractApplicationContext createApplicationContext() {
+        return new ClassPathXmlApplicationContext("org/apache/camel/component/jms/config/JmsEndpointWithCustomDestinationTest-context.xml");
+    }
+
     @Test
     public void testMessageSentToCustomEndpoint() throws Exception {
+        ActiveMQQueue jmsQueue = context.getRegistry().lookup("jmsQueue", ActiveMQQueue.class);
         assertNotNull("jmsQueue", jmsQueue);
         assertEquals("jmsqueue.getPhysicalName()", "Test.Camel.CustomEndpoint", jmsQueue.getPhysicalName());
 
-        result.expectedBodiesReceived(expectedBody);
+        getMockEndpoint("mock:result").expectedBodiesReceived(expectedBody);
 
-        template.sendBody(expectedBody);
+        template.sendBody("direct:start", expectedBody);
 
-        result.assertIsSatisfied();
+        assertMockEndpointsSatisfied();
     }
 
 }

Modified: camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/issues/JmsRedeliveryWithInitialRedeliveryDelayTest.java
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/issues/JmsRedeliveryWithInitialRedeliveryDelayTest.java?rev=1100567&r1=1100566&r2=1100567&view=diff
==============================================================================
--- camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/issues/JmsRedeliveryWithInitialRedeliveryDelayTest.java (original)
+++ camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/issues/JmsRedeliveryWithInitialRedeliveryDelayTest.java Sat May  7 16:49:24 2011
@@ -16,26 +16,22 @@
  */
 package org.apache.camel.component.jms.issues;
 
-import org.apache.camel.CamelContext;
 import org.apache.camel.Exchange;
-import org.apache.camel.ProducerTemplate;
 import org.apache.camel.component.mock.MockEndpoint;
+import org.apache.camel.test.junit4.CamelSpringTestSupport;
 import org.junit.Test;
-import org.springframework.beans.factory.annotation.Autowired;
-import org.springframework.test.context.ContextConfiguration;
-import org.springframework.test.context.junit4.AbstractJUnit4SpringContextTests;
+import org.springframework.context.support.AbstractApplicationContext;
+import org.springframework.context.support.ClassPathXmlApplicationContext;
 
 /**
  * Unit test to verify DLC and JMS based on user reporting
  */
-@ContextConfiguration
-public class JmsRedeliveryWithInitialRedeliveryDelayTest extends AbstractJUnit4SpringContextTests {
+public class JmsRedeliveryWithInitialRedeliveryDelayTest extends CamelSpringTestSupport {
 
-    @Autowired
-    protected CamelContext context;
-
-    @Autowired
-    protected ProducerTemplate template;
+    @Override
+    protected AbstractApplicationContext createApplicationContext() {
+        return new ClassPathXmlApplicationContext("org/apache/camel/component/jms/issues/JmsRedeliveryWithInitialRedeliveryDelayTest-context.xml");
+    }
 
     @Test
     public void testDLCSpringConfiguredRedeliveryPolicy() throws Exception {
@@ -49,7 +45,6 @@ public class JmsRedeliveryWithInitialRed
 
         template.sendBody("activemq:in", "Hello World");
 
-        result.assertIsSatisfied();
-        dead.assertIsSatisfied();
+        assertMockEndpointsSatisfied();
     }
 }

Modified: camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/issues/JmsResequencerTest.java
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/issues/JmsResequencerTest.java?rev=1100567&r1=1100566&r2=1100567&view=diff
==============================================================================
--- camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/issues/JmsResequencerTest.java (original)
+++ camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/issues/JmsResequencerTest.java Sat May  7 16:49:24 2011
@@ -16,36 +16,22 @@
  */
 package org.apache.camel.component.jms.issues;
 
-import org.apache.camel.CamelContext;
-import org.apache.camel.EndpointInject;
-import org.apache.camel.ProducerTemplate;
 import org.apache.camel.component.mock.MockEndpoint;
-import org.junit.After;
+import org.apache.camel.test.junit4.CamelSpringTestSupport;
 import org.junit.Test;
-import org.springframework.beans.factory.annotation.Autowired;
-import org.springframework.test.context.ContextConfiguration;
-import org.springframework.test.context.junit4.AbstractJUnit4SpringContextTests;
+import org.springframework.context.support.AbstractApplicationContext;
+import org.springframework.context.support.ClassPathXmlApplicationContext;
 
 /**
  * Unit test for issues CAMEL-1034 and CAMEL-1037
  */
-@ContextConfiguration
-public class JmsResequencerTest extends AbstractJUnit4SpringContextTests {
+public class JmsResequencerTest extends CamelSpringTestSupport {
 
-    @Autowired
-    protected CamelContext context;
-
-    @EndpointInject(uri = "mock:result")
-    protected MockEndpoint result;
-
-    @Autowired
-    protected ProducerTemplate template;
-    
-    @After
-    public void tearDown() {
-        result.reset();
+    @Override
+    protected AbstractApplicationContext createApplicationContext() {
+        return new ClassPathXmlApplicationContext("org/apache/camel/component/jms/issues/JmsResequencerTest-context.xml");
     }
-    
+
     @Test
     public void testBatchResequencer() throws Exception {
         testResequencer("activemq:queue:in1");
@@ -57,14 +43,18 @@ public class JmsResequencerTest extends 
     }
     
     private void testResequencer(String endpoint) throws Exception {
+        MockEndpoint result = getMockEndpoint("mock:result");
         result.expectedMessageCount(100);
+
         for (int i = 0; i < 100; i++) {
             result.message(i).body().isEqualTo(Integer.valueOf(i + 1));
         }
+
         for (int i = 100; i > 0; i--) {
             template.sendBodyAndHeader(endpoint, Integer.valueOf(i), "num", Long.valueOf(i));
         }
-        result.assertIsSatisfied();
+
+        assertMockEndpointsSatisfied();
     }
 
 }

Added: camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/issues/MyFailureProcessor.java
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/issues/MyFailureProcessor.java?rev=1100567&view=auto
==============================================================================
--- camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/issues/MyFailureProcessor.java (added)
+++ camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/issues/MyFailureProcessor.java Sat May  7 16:49:24 2011
@@ -0,0 +1,31 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.camel.component.jms.issues;
+
+import org.apache.camel.Exchange;
+import org.apache.camel.Processor;
+
+/**
+ *
+ */
+public class MyFailureProcessor implements Processor {
+
+    public void process(Exchange exchange) throws Exception {
+        throw new IllegalArgumentException("Unit test - this is thrown by intention");
+    }
+
+}

Modified: camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/issues/TransactionErrorHandlerRedeliveryDelayTest.java
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/issues/TransactionErrorHandlerRedeliveryDelayTest.java?rev=1100567&r1=1100566&r2=1100567&view=diff
==============================================================================
--- camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/issues/TransactionErrorHandlerRedeliveryDelayTest.java (original)
+++ camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/issues/TransactionErrorHandlerRedeliveryDelayTest.java Sat May  7 16:49:24 2011
@@ -16,44 +16,32 @@
  */
 package org.apache.camel.component.jms.issues;
 
-import org.apache.camel.CamelContext;
-import org.apache.camel.EndpointInject;
 import org.apache.camel.Exchange;
 import org.apache.camel.Processor;
-import org.apache.camel.ProducerTemplate;
-import org.apache.camel.component.mock.MockEndpoint;
+import org.apache.camel.test.junit4.CamelSpringTestSupport;
 import org.junit.Test;
-import org.springframework.beans.factory.annotation.Autowired;
-import org.springframework.test.context.ContextConfiguration;
-import org.springframework.test.context.junit4.AbstractJUnit4SpringContextTests;
-
-import static org.junit.Assert.assertTrue;
+import org.springframework.context.support.AbstractApplicationContext;
+import org.springframework.context.support.ClassPathXmlApplicationContext;
 
 /**
  * Unit test for issue CAMEL-706
  */
-@ContextConfiguration
-public class TransactionErrorHandlerRedeliveryDelayTest extends AbstractJUnit4SpringContextTests {
-
-    private static int counter;
+public class TransactionErrorHandlerRedeliveryDelayTest extends CamelSpringTestSupport {
 
-    @Autowired
-    protected CamelContext context;
+    private static volatile int counter;
 
-    @Autowired
-    protected ProducerTemplate producer;
-
-    @EndpointInject(uri = "mock:result")
-    protected MockEndpoint result;
+    @Override
+    protected AbstractApplicationContext createApplicationContext() {
+        return new ClassPathXmlApplicationContext("org/apache/camel/component/jms/issues/TransactionErrorHandlerRedeliveryDelayTest-context.xml");
+    }
 
     @Test
     public void testTransactedRedeliveryDelay() throws Exception {
-        result.expectedMessageCount(1);
-        result.expectedBodiesReceived("Bye World");
+        getMockEndpoint("mock:result").expectedBodiesReceived("Bye World");
 
-        producer.sendBody("activemq:queue:in", "Hello World");
+        template.sendBody("activemq:queue:in", "Hello World");
 
-        result.assertIsSatisfied();
+        assertMockEndpointsSatisfied();
     }
 
     public static class MyFailureProcessor implements Processor {

Added: camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/remoting/ISay.java
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/remoting/ISay.java?rev=1100567&view=auto
==============================================================================
--- camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/remoting/ISay.java (added)
+++ camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/remoting/ISay.java Sat May  7 16:49:24 2011
@@ -0,0 +1,27 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.camel.component.jms.remoting;
+
+import java.rmi.Remote;
+import java.rmi.RemoteException;
+
+/**
+ *
+ */
+public interface ISay extends Remote {
+    String say() throws RemoteException;
+}

Modified: camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/remoting/JmsRemotingTest.java
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/remoting/JmsRemotingTest.java?rev=1100567&r1=1100566&r2=1100567&view=diff
==============================================================================
--- camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/remoting/JmsRemotingTest.java (original)
+++ camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/remoting/JmsRemotingTest.java Sat May  7 16:49:24 2011
@@ -16,15 +16,28 @@
  */
 package org.apache.camel.component.jms.remoting;
 
-import org.apache.camel.spring.remoting.SpringRemotingRouteTest;
+import org.apache.camel.test.junit4.CamelSpringTestSupport;
+import org.junit.Test;
 import org.springframework.context.support.ClassPathXmlApplicationContext;
 
 /**
  * @version 
  */
-public class JmsRemotingTest extends SpringRemotingRouteTest {
+public class JmsRemotingTest extends CamelSpringTestSupport {
 
     protected ClassPathXmlApplicationContext createApplicationContext() {
         return new ClassPathXmlApplicationContext("org/apache/camel/component/jms/remoting/spring.xml");
     }
+
+    @Override
+    protected int getExpectedRouteCount() {
+        return 0;
+    }
+
+    @Test
+    public void testRemoting() throws Exception {
+        ISay proxy = (ISay) applicationContext.getBean("sayProxy");
+        String rc = proxy.say();
+        assertEquals("Hello", rc);
+    }
 }
\ No newline at end of file

Added: camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/remoting/SayService.java
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/remoting/SayService.java?rev=1100567&view=auto
==============================================================================
--- camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/remoting/SayService.java (added)
+++ camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/remoting/SayService.java Sat May  7 16:49:24 2011
@@ -0,0 +1,51 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.camel.component.jms.remoting;
+
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+/**
+ *
+ */
+public class SayService implements ISay {
+
+    private static final Logger LOG = LoggerFactory.getLogger(SayService.class);
+
+    String message = "Hello";
+
+    public SayService() {
+    }
+
+    public SayService(String message) {
+        this.message = message;
+    }
+
+    public String say() {
+        LOG.info("Invoking say() method with message: " + message);
+
+        return message;
+    }
+
+    public String getMessage() {
+        return message;
+    }
+
+    public void setMessage(String message) {
+        this.message = message;
+    }
+}

Modified: camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/tx/AsyncEndpointJmsTX2Test.java
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/tx/AsyncEndpointJmsTX2Test.java?rev=1100567&r1=1100566&r2=1100567&view=diff
==============================================================================
--- camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/tx/AsyncEndpointJmsTX2Test.java (original)
+++ camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/tx/AsyncEndpointJmsTX2Test.java Sat May  7 16:49:24 2011
@@ -19,7 +19,7 @@ package org.apache.camel.component.jms.t
 import org.apache.camel.Exchange;
 import org.apache.camel.Processor;
 import org.apache.camel.builder.RouteBuilder;
-import org.apache.camel.processor.async.MyAsyncComponent;
+import org.apache.camel.component.jms.async.MyAsyncComponent;
 import org.apache.camel.test.junit4.CamelSpringTestSupport;
 import org.junit.Test;
 import org.springframework.context.support.AbstractXmlApplicationContext;

Modified: camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/tx/AsyncEndpointJmsTXMulticastTest.java
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/tx/AsyncEndpointJmsTXMulticastTest.java?rev=1100567&r1=1100566&r2=1100567&view=diff
==============================================================================
--- camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/tx/AsyncEndpointJmsTXMulticastTest.java (original)
+++ camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/tx/AsyncEndpointJmsTXMulticastTest.java Sat May  7 16:49:24 2011
@@ -19,7 +19,7 @@ package org.apache.camel.component.jms.t
 import org.apache.camel.Exchange;
 import org.apache.camel.Processor;
 import org.apache.camel.builder.RouteBuilder;
-import org.apache.camel.processor.async.MyAsyncComponent;
+import org.apache.camel.component.jms.async.MyAsyncComponent;
 import org.apache.camel.test.junit4.CamelSpringTestSupport;
 import org.junit.Test;
 import org.springframework.context.support.AbstractXmlApplicationContext;

Modified: camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/tx/AsyncEndpointJmsTXRecipientListTest.java
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/tx/AsyncEndpointJmsTXRecipientListTest.java?rev=1100567&r1=1100566&r2=1100567&view=diff
==============================================================================
--- camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/tx/AsyncEndpointJmsTXRecipientListTest.java (original)
+++ camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/tx/AsyncEndpointJmsTXRecipientListTest.java Sat May  7 16:49:24 2011
@@ -19,7 +19,7 @@ package org.apache.camel.component.jms.t
 import org.apache.camel.Exchange;
 import org.apache.camel.Processor;
 import org.apache.camel.builder.RouteBuilder;
-import org.apache.camel.processor.async.MyAsyncComponent;
+import org.apache.camel.component.jms.async.MyAsyncComponent;
 import org.apache.camel.test.junit4.CamelSpringTestSupport;
 import org.junit.Test;
 import org.springframework.context.support.AbstractXmlApplicationContext;

Modified: camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/tx/AsyncEndpointJmsTXRollback2Test.java
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/tx/AsyncEndpointJmsTXRollback2Test.java?rev=1100567&r1=1100566&r2=1100567&view=diff
==============================================================================
--- camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/tx/AsyncEndpointJmsTXRollback2Test.java (original)
+++ camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/tx/AsyncEndpointJmsTXRollback2Test.java Sat May  7 16:49:24 2011
@@ -19,7 +19,7 @@ package org.apache.camel.component.jms.t
 import org.apache.camel.Exchange;
 import org.apache.camel.Processor;
 import org.apache.camel.builder.RouteBuilder;
-import org.apache.camel.processor.async.MyAsyncComponent;
+import org.apache.camel.component.jms.async.MyAsyncComponent;
 import org.apache.camel.test.junit4.CamelSpringTestSupport;
 import org.junit.Test;
 import org.springframework.context.support.AbstractXmlApplicationContext;

Modified: camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/tx/AsyncEndpointJmsTXRollbackTest.java
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/tx/AsyncEndpointJmsTXRollbackTest.java?rev=1100567&r1=1100566&r2=1100567&view=diff
==============================================================================
--- camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/tx/AsyncEndpointJmsTXRollbackTest.java (original)
+++ camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/tx/AsyncEndpointJmsTXRollbackTest.java Sat May  7 16:49:24 2011
@@ -19,7 +19,7 @@ package org.apache.camel.component.jms.t
 import org.apache.camel.Exchange;
 import org.apache.camel.Processor;
 import org.apache.camel.builder.RouteBuilder;
-import org.apache.camel.processor.async.MyAsyncComponent;
+import org.apache.camel.component.jms.async.MyAsyncComponent;
 import org.apache.camel.test.junit4.CamelSpringTestSupport;
 import org.junit.Test;
 import org.springframework.context.support.AbstractXmlApplicationContext;

Modified: camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/tx/AsyncEndpointJmsTXRoutingSlipTest.java
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/tx/AsyncEndpointJmsTXRoutingSlipTest.java?rev=1100567&r1=1100566&r2=1100567&view=diff
==============================================================================
--- camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/tx/AsyncEndpointJmsTXRoutingSlipTest.java (original)
+++ camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/tx/AsyncEndpointJmsTXRoutingSlipTest.java Sat May  7 16:49:24 2011
@@ -19,7 +19,7 @@ package org.apache.camel.component.jms.t
 import org.apache.camel.Exchange;
 import org.apache.camel.Processor;
 import org.apache.camel.builder.RouteBuilder;
-import org.apache.camel.processor.async.MyAsyncComponent;
+import org.apache.camel.component.jms.async.MyAsyncComponent;
 import org.apache.camel.test.junit4.CamelSpringTestSupport;
 import org.junit.Test;
 import org.springframework.context.support.AbstractXmlApplicationContext;

Modified: camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/tx/AsyncEndpointJmsTXTest.java
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/tx/AsyncEndpointJmsTXTest.java?rev=1100567&r1=1100566&r2=1100567&view=diff
==============================================================================
--- camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/tx/AsyncEndpointJmsTXTest.java (original)
+++ camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/tx/AsyncEndpointJmsTXTest.java Sat May  7 16:49:24 2011
@@ -19,7 +19,7 @@ package org.apache.camel.component.jms.t
 import org.apache.camel.Exchange;
 import org.apache.camel.Processor;
 import org.apache.camel.builder.RouteBuilder;
-import org.apache.camel.processor.async.MyAsyncComponent;
+import org.apache.camel.component.jms.async.MyAsyncComponent;
 import org.apache.camel.test.junit4.CamelSpringTestSupport;
 import org.junit.Test;
 import org.springframework.context.support.AbstractXmlApplicationContext;

Modified: camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/tx/AsyncEndpointJmsTXTryCatchFinallyTest.java
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/tx/AsyncEndpointJmsTXTryCatchFinallyTest.java?rev=1100567&r1=1100566&r2=1100567&view=diff
==============================================================================
--- camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/tx/AsyncEndpointJmsTXTryCatchFinallyTest.java (original)
+++ camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/tx/AsyncEndpointJmsTXTryCatchFinallyTest.java Sat May  7 16:49:24 2011
@@ -19,7 +19,7 @@ package org.apache.camel.component.jms.t
 import org.apache.camel.Exchange;
 import org.apache.camel.Processor;
 import org.apache.camel.builder.RouteBuilder;
-import org.apache.camel.processor.async.MyAsyncComponent;
+import org.apache.camel.component.jms.async.MyAsyncComponent;
 import org.apache.camel.test.junit4.CamelSpringTestSupport;
 import org.junit.Test;
 import org.springframework.context.support.AbstractXmlApplicationContext;

Modified: camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/tx/AsyncEndpointJmsTXWireTapTest.java
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/tx/AsyncEndpointJmsTXWireTapTest.java?rev=1100567&r1=1100566&r2=1100567&view=diff
==============================================================================
--- camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/tx/AsyncEndpointJmsTXWireTapTest.java (original)
+++ camel/trunk/components/camel-jms/src/test/java/org/apache/camel/component/jms/tx/AsyncEndpointJmsTXWireTapTest.java Sat May  7 16:49:24 2011
@@ -19,7 +19,7 @@ package org.apache.camel.component.jms.t
 import org.apache.camel.Exchange;
 import org.apache.camel.Processor;
 import org.apache.camel.builder.RouteBuilder;
-import org.apache.camel.processor.async.MyAsyncComponent;
+import org.apache.camel.component.jms.async.MyAsyncComponent;
 import org.apache.camel.test.junit4.CamelSpringTestSupport;
 import org.junit.Test;
 import org.springframework.context.support.AbstractXmlApplicationContext;

Modified: camel/trunk/components/camel-jms/src/test/resources/org/apache/camel/component/jms/issues/JmsRedeliveryWithInitialRedeliveryDelayTest-context.xml
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-jms/src/test/resources/org/apache/camel/component/jms/issues/JmsRedeliveryWithInitialRedeliveryDelayTest-context.xml?rev=1100567&r1=1100566&r2=1100567&view=diff
==============================================================================
--- camel/trunk/components/camel-jms/src/test/resources/org/apache/camel/component/jms/issues/JmsRedeliveryWithInitialRedeliveryDelayTest-context.xml (original)
+++ camel/trunk/components/camel-jms/src/test/resources/org/apache/camel/component/jms/issues/JmsRedeliveryWithInitialRedeliveryDelayTest-context.xml Sat May  7 16:49:24 2011
@@ -45,7 +45,7 @@
         <property name="handled" value="false"/>
     </bean>
 
-    <bean id="myFailureProcessor" class="org.apache.camel.spring.config.MyFailureProcessor"/>
+    <bean id="myFailureProcessor" class="org.apache.camel.component.jms.issues.MyFailureProcessor"/>
 
     <bean id="myRedeliveryPolicyConfig" class="org.apache.camel.processor.RedeliveryPolicy">
         <property name="maximumRedeliveries" value="4"/>

Modified: camel/trunk/components/camel-jms/src/test/resources/org/apache/camel/component/jms/remoting/spring.xml
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-jms/src/test/resources/org/apache/camel/component/jms/remoting/spring.xml?rev=1100567&r1=1100566&r2=1100567&view=diff
==============================================================================
--- camel/trunk/components/camel-jms/src/test/resources/org/apache/camel/component/jms/remoting/spring.xml (original)
+++ camel/trunk/components/camel-jms/src/test/resources/org/apache/camel/component/jms/remoting/spring.xml Sat May  7 16:49:24 2011
@@ -23,18 +23,17 @@
        http://camel.apache.org/schema/spring http://camel.apache.org/schema/spring/camel-spring.xsd
     ">
 
-  <bean id="sayService" class="org.apache.camel.spring.remoting.SayService" scope="singleton"/>
+  <bean id="sayService" class="org.apache.camel.component.jms.remoting.SayService" scope="singleton"/>
 
   <camelContext id="camel" xmlns="http://camel.apache.org/schema/spring">
       <jmxAgent id="agent" disabled="true"/>
     <!-- create the client proxy -->
     <proxy id="sayProxy" serviceUrl="activemq:test.serviceQueue"
-           serviceInterface="org.apache.camel.spring.remoting.ISay"/>
+           serviceInterface="org.apache.camel.component.jms.remoting.ISay"/>
 
     <!-- export the service -->
     <export id="say" uri="activemq:test.serviceQueue" serviceRef="sayService"
-            serviceInterface="org.apache.camel.spring.remoting.ISay"/>
-
+            serviceInterface="org.apache.camel.component.jms.remoting.ISay"/>
   </camelContext>
 
   <!-- configure the ActiveMQ component -->

Modified: camel/trunk/components/camel-spring/pom.xml
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-spring/pom.xml?rev=1100567&r1=1100566&r2=1100567&view=diff
==============================================================================
--- camel/trunk/components/camel-spring/pom.xml (original)
+++ camel/trunk/components/camel-spring/pom.xml Sat May  7 16:49:24 2011
@@ -254,10 +254,7 @@
             <phase>package</phase>
             <configuration>
               <tasks>
-                <echo>Deleting unwanted resources from the test-jar</echo>
-                <delete file="${project.build.directory}/test-classes/log4j.properties" verbose="true" />
-                <delete file="${project.build.directory}/test-classes/META-INF/spring/*" verbose="true" />
-
+                <echo>Including source code from camel-core-xml in the camel-spring-sources.ar</echo>
                 <jar destfile="${project.build.directory}/${project.artifactId}-${project.version}-sources.jar" update="true">
                   <fileset dir="${basedir}/../camel-core-osgi/src/main/java" includes="**/*" />
                   <fileset dir="${basedir}/../camel-core-xml/src/main/java" includes="**/*" />
@@ -294,24 +291,6 @@
         </executions>
       </plugin>
         
-        <!-- generate the attached tests jar -->
-      <plugin>
-        <artifactId>maven-jar-plugin</artifactId>
-        <executions>
-          <execution>
-            <goals>
-              <goal>test-jar</goal>
-            </goals>
-          </execution>
-        </executions>
-        <configuration>
-          <!-- TODO: this doesn't work - if ever we can figure out the maven ninja to get it working -->
-          <!-- TODO: we can zap the Ant package phase stuff above -->
-          <excludes>
-            <exclude>**/*/log4j.properties</exclude>
-          </excludes>
-        </configuration>
-      </plugin>
     </plugins>
 
     <pluginManagement>

Modified: camel/trunk/components/camel-spring/src/test/java/org/apache/camel/spring/remoting/SpringRemotingRouteTest.java
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-spring/src/test/java/org/apache/camel/spring/remoting/SpringRemotingRouteTest.java?rev=1100567&r1=1100566&r2=1100567&view=diff
==============================================================================
--- camel/trunk/components/camel-spring/src/test/java/org/apache/camel/spring/remoting/SpringRemotingRouteTest.java (original)
+++ camel/trunk/components/camel-spring/src/test/java/org/apache/camel/spring/remoting/SpringRemotingRouteTest.java Sat May  7 16:49:24 2011
@@ -29,12 +29,6 @@ public class SpringRemotingRouteTest ext
     
     public void testBeanRoutes() throws Exception {
         AbstractXmlApplicationContext applicationContext = createApplicationContext();
-/*
-        Object service = applicationContext.getBean("say");
-        log.info("Found service!: " + service);
-        assertTrue("not an ISay!", service instanceof ISay);
-*/
-
         CamelContext camelContext = SpringCamelContext.springCamelContext(applicationContext);
 
         // START SNIPPET: invoke

Modified: camel/trunk/parent/pom.xml
URL: http://svn.apache.org/viewvc/camel/trunk/parent/pom.xml?rev=1100567&r1=1100566&r2=1100567&view=diff
==============================================================================
--- camel/trunk/parent/pom.xml (original)
+++ camel/trunk/parent/pom.xml Sat May  7 16:49:24 2011
@@ -850,12 +850,6 @@
         <type>test-jar</type>
         <version>${project.version}</version>
       </dependency>
-      <dependency>
-        <groupId>org.apache.camel</groupId>
-        <artifactId>camel-spring</artifactId>
-        <type>test-jar</type>
-        <version>${project.version}</version>
-      </dependency>
 
       <!-- Required dependencies -->
       <dependency>

Modified: camel/trunk/tests/camel-partial-classpath-test/pom.xml
URL: http://svn.apache.org/viewvc/camel/trunk/tests/camel-partial-classpath-test/pom.xml?rev=1100567&r1=1100566&r2=1100567&view=diff
==============================================================================
--- camel/trunk/tests/camel-partial-classpath-test/pom.xml (original)
+++ camel/trunk/tests/camel-partial-classpath-test/pom.xml Sat May  7 16:49:24 2011
@@ -55,14 +55,13 @@
 
     <!-- testing -->
     <dependency>
-      <groupId>junit</groupId>
-      <artifactId>junit</artifactId>
+      <groupId>org.apache.camel</groupId>
+      <artifactId>camel-test</artifactId>
       <scope>test</scope>
     </dependency>
     <dependency>
-      <groupId>org.apache.camel</groupId>
-      <artifactId>camel-core</artifactId>
-      <type>test-jar</type>
+      <groupId>junit</groupId>
+      <artifactId>junit</artifactId>
       <scope>test</scope>
     </dependency>
     <dependency>

Modified: camel/trunk/tests/camel-partial-classpath-test/src/test/java/org/apache/camel/tests/partialclasspath/RouteTest.java
URL: http://svn.apache.org/viewvc/camel/trunk/tests/camel-partial-classpath-test/src/test/java/org/apache/camel/tests/partialclasspath/RouteTest.java?rev=1100567&r1=1100566&r2=1100567&view=diff
==============================================================================
--- camel/trunk/tests/camel-partial-classpath-test/src/test/java/org/apache/camel/tests/partialclasspath/RouteTest.java (original)
+++ camel/trunk/tests/camel-partial-classpath-test/src/test/java/org/apache/camel/tests/partialclasspath/RouteTest.java Sat May  7 16:49:24 2011
@@ -16,15 +16,17 @@
  */
 package org.apache.camel.tests.partialclasspath;
 
-import org.apache.camel.ContextTestSupport;
 import org.apache.camel.builder.RouteBuilder;
 import org.apache.camel.component.mock.MockEndpoint;
+import org.apache.camel.test.junit4.CamelTestSupport;
+import org.junit.Test;
 
 /**
  * @version 
  */
-public class RouteTest extends ContextTestSupport {
+public class RouteTest extends CamelTestSupport {
 
+    @Test
     public void testRoute() throws Exception {
         MockEndpoint resultEndpoint = resolveMandatoryEndpoint("mock:result", MockEndpoint.class);
         resultEndpoint.expectedBodiesReceived(new MyBean("foo", "bar"));
@@ -34,7 +36,6 @@ public class RouteTest extends ContextTe
         resultEndpoint.assertIsSatisfied();
     }
 
-
     protected RouteBuilder createRouteBuilder() {
         return new RouteBuilder() {
             public void configure() {



Mime
View raw message