camel-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jstrac...@apache.org
Subject svn commit: r572571 - in /activemq/camel/trunk/tests: ./ camel-partial-classpath-test/ camel-partial-classpath-test/src/ camel-partial-classpath-test/src/test/ camel-partial-classpath-test/src/test/java/ camel-partial-classpath-test/src/test/java/org/ ...
Date Tue, 04 Sep 2007 08:18:55 GMT
Author: jstrachan
Date: Tue Sep  4 01:18:53 2007
New Revision: 572571

URL: http://svn.apache.org/viewvc?rev=572571&view=rev
Log:
attempted to create a test case for CAMEL-100 (though failed)

Added:
    activemq/camel/trunk/tests/camel-partial-classpath-test/
    activemq/camel/trunk/tests/camel-partial-classpath-test/pom.xml   (with props)
    activemq/camel/trunk/tests/camel-partial-classpath-test/src/
    activemq/camel/trunk/tests/camel-partial-classpath-test/src/test/
    activemq/camel/trunk/tests/camel-partial-classpath-test/src/test/java/
    activemq/camel/trunk/tests/camel-partial-classpath-test/src/test/java/org/
    activemq/camel/trunk/tests/camel-partial-classpath-test/src/test/java/org/apache/
    activemq/camel/trunk/tests/camel-partial-classpath-test/src/test/java/org/apache/camel/
    activemq/camel/trunk/tests/camel-partial-classpath-test/src/test/java/org/apache/camel/tests/
    activemq/camel/trunk/tests/camel-partial-classpath-test/src/test/java/org/apache/camel/tests/partialclasspath/
    activemq/camel/trunk/tests/camel-partial-classpath-test/src/test/java/org/apache/camel/tests/partialclasspath/RouteTest.java
      - copied, changed from r572553, activemq/camel/trunk/camel-core/src/test/java/org/apache/camel/processor/FilterTest.java
    activemq/camel/trunk/tests/camel-partial-classpath-test/src/test/resources/
    activemq/camel/trunk/tests/camel-partial-classpath-test/src/test/resources/log4j.properties
      - copied unchanged from r572553, activemq/camel/trunk/camel-core/src/test/resources/log4j.properties
Modified:
    activemq/camel/trunk/tests/pom.xml

Added: activemq/camel/trunk/tests/camel-partial-classpath-test/pom.xml
URL: http://svn.apache.org/viewvc/activemq/camel/trunk/tests/camel-partial-classpath-test/pom.xml?rev=572571&view=auto
==============================================================================
--- activemq/camel/trunk/tests/camel-partial-classpath-test/pom.xml (added)
+++ activemq/camel/trunk/tests/camel-partial-classpath-test/pom.xml Tue Sep  4 01:18:53 2007
@@ -0,0 +1,88 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<!--
+  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.
+-->
+
+<project xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd"
+  xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://maven.apache.org/POM/4.0.0">
+
+  <modelVersion>4.0.0</modelVersion>
+
+  <parent>
+    <groupId>org.apache.camel</groupId>
+    <artifactId>camel-parent</artifactId>
+    <version>1.1-SNAPSHOT</version>
+  </parent>
+
+  <artifactId>camel-partial-classpath-test</artifactId>
+  <name>Camel :: Partial Classpath Tests</name>
+  <description>Performs integration tests with incomplete classpaths</description>
+
+  <dependencies>
+    <dependency>
+      <groupId>org.apache.camel</groupId>
+      <artifactId>camel-core</artifactId>
+    </dependency>
+    <dependency>
+      <groupId>org.apache.camel</groupId>
+      <artifactId>camel-activemq</artifactId>
+      <exclusions>
+        <exclusion>
+          <groupId>org.apache.activemq</groupId>
+          <artifactId>activemq-core</artifactId>
+        </exclusion>
+        <exclusion>
+          <groupId>org.apache.activemq</groupId>
+          <artifactId>activemq-all</artifactId>
+        </exclusion>
+      </exclusions>
+    </dependency>
+    <dependency>
+      <groupId>org.apache.camel</groupId>
+      <artifactId>camel-jms</artifactId>
+      <exclusions>
+        <exclusion>
+          <groupId>org.apache.activemq</groupId>
+          <artifactId>activemq-core</artifactId>
+        </exclusion>
+        <exclusion>
+          <groupId>org.apache.activemq</groupId>
+          <artifactId>activemq-all</artifactId>
+        </exclusion>
+      </exclusions>
+    </dependency>
+
+    <!-- testing -->
+    <dependency>
+      <groupId>junit</groupId>
+      <artifactId>junit</artifactId>
+    </dependency>
+    <dependency>
+      <groupId>org.apache.camel</groupId>
+      <artifactId>camel-core</artifactId>
+      <type>test-jar</type>
+    </dependency>
+    <dependency>
+      <groupId>commons-logging</groupId>
+      <artifactId>commons-logging</artifactId>
+    </dependency>
+    <dependency>
+      <groupId>log4j</groupId>
+      <artifactId>log4j</artifactId>
+    </dependency>
+  </dependencies>
+</project>

Propchange: activemq/camel/trunk/tests/camel-partial-classpath-test/pom.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Copied: activemq/camel/trunk/tests/camel-partial-classpath-test/src/test/java/org/apache/camel/tests/partialclasspath/RouteTest.java
(from r572553, activemq/camel/trunk/camel-core/src/test/java/org/apache/camel/processor/FilterTest.java)
URL: http://svn.apache.org/viewvc/activemq/camel/trunk/tests/camel-partial-classpath-test/src/test/java/org/apache/camel/tests/partialclasspath/RouteTest.java?p2=activemq/camel/trunk/tests/camel-partial-classpath-test/src/test/java/org/apache/camel/tests/partialclasspath/RouteTest.java&p1=activemq/camel/trunk/camel-core/src/test/java/org/apache/camel/processor/FilterTest.java&r1=572553&r2=572571&rev=572571&view=diff
==============================================================================
--- activemq/camel/trunk/camel-core/src/test/java/org/apache/camel/processor/FilterTest.java
(original)
+++ activemq/camel/trunk/tests/camel-partial-classpath-test/src/test/java/org/apache/camel/tests/partialclasspath/RouteTest.java
Tue Sep  4 01:18:53 2007
@@ -14,7 +14,7 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package org.apache.camel.processor;
+package org.apache.camel.tests.partialclasspath;
 
 import org.apache.camel.ContextTestSupport;
 import org.apache.camel.builder.RouteBuilder;
@@ -23,22 +23,13 @@
 /**
  * @version $Revision: 1.1 $
  */
-public class FilterTest extends ContextTestSupport {
+public class RouteTest extends ContextTestSupport {
 
-    public void testSendMatchingMessage() throws Exception {
+    public void testRoute() throws Exception {
         MockEndpoint resultEndpoint = resolveMandatoryEndpoint("mock:result", MockEndpoint.class);
-        resultEndpoint.expectedMessageCount(1);
+        resultEndpoint.expectedBodiesReceived("123");
 
-        template.sendBodyAndHeader("direct:start", "<matched/>", "foo", "bar");
-
-        resultEndpoint.assertIsSatisfied();
-    }
-
-    public void testSendNotMatchingMessage() throws Exception {
-        MockEndpoint resultEndpoint = resolveMandatoryEndpoint("mock:result", MockEndpoint.class);
-        resultEndpoint.expectedMessageCount(0);
-
-        template.sendBodyAndHeader("direct:start", "<notMatched/>", "foo", "notMatchedHeaderValue");
+        template.sendBody("direct:start", 123);
 
         resultEndpoint.assertIsSatisfied();
     }
@@ -47,9 +38,9 @@
     protected RouteBuilder createRouteBuilder() {
         return new RouteBuilder() {
             public void configure() {
-                from("direct:start").filter(header("foo").isEqualTo("bar")).to("mock:result");
+                from("direct:start").convertBodyTo(String.class).to("mock:result");
             }
         };
     }
 
-}
+}
\ No newline at end of file

Modified: activemq/camel/trunk/tests/pom.xml
URL: http://svn.apache.org/viewvc/activemq/camel/trunk/tests/pom.xml?rev=572571&r1=572570&r2=572571&view=diff
==============================================================================
--- activemq/camel/trunk/tests/pom.xml (original)
+++ activemq/camel/trunk/tests/pom.xml Tue Sep  4 01:18:53 2007
@@ -35,6 +35,7 @@
 
   <modules>
     <module>camel-itest</module>
+    <module>camel-partial-classpath-test</module>
   </modules>
 
 </project>



Mime
View raw message