You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@camel.apache.org by da...@apache.org on 2017/06/29 11:37:36 UTC

[1/9] camel git commit: CAMEL-11477: Can not override isUseAdviceWith in CamelBlueprintTestSupport

Repository: camel
Updated Branches:
  refs/heads/camel-2.18.x e010a3f3e -> e0c5b1483
  refs/heads/camel-2.19.x a20296085 -> 961d4f693
  refs/heads/master 5b985f4ff -> 35f172e69


CAMEL-11477: Can not override isUseAdviceWith in CamelBlueprintTestSupport


Project: http://git-wip-us.apache.org/repos/asf/camel/repo
Commit: http://git-wip-us.apache.org/repos/asf/camel/commit/dd4ba921
Tree: http://git-wip-us.apache.org/repos/asf/camel/tree/dd4ba921
Diff: http://git-wip-us.apache.org/repos/asf/camel/diff/dd4ba921

Branch: refs/heads/master
Commit: dd4ba92114c80168bf64f9d703a5710ce01ff868
Parents: 5b985f4
Author: Saravanakumar Selvaraj <ss...@ssaravan.pnq.csb>
Authored: Thu Jun 29 10:33:43 2017 +0530
Committer: Claus Ibsen <da...@apache.org>
Committed: Thu Jun 29 12:44:29 2017 +0200

----------------------------------------------------------------------
 .../apache/camel/test/blueprint/CamelBlueprintTestSupport.java | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/camel/blob/dd4ba921/components/camel-test-blueprint/src/main/java/org/apache/camel/test/blueprint/CamelBlueprintTestSupport.java
----------------------------------------------------------------------
diff --git a/components/camel-test-blueprint/src/main/java/org/apache/camel/test/blueprint/CamelBlueprintTestSupport.java b/components/camel-test-blueprint/src/main/java/org/apache/camel/test/blueprint/CamelBlueprintTestSupport.java
index 566ccaa..cddfaea 100644
--- a/components/camel-test-blueprint/src/main/java/org/apache/camel/test/blueprint/CamelBlueprintTestSupport.java
+++ b/components/camel-test-blueprint/src/main/java/org/apache/camel/test/blueprint/CamelBlueprintTestSupport.java
@@ -248,7 +248,11 @@ public abstract class CamelBlueprintTestSupport extends CamelTestSupport {
 
         // start context when we are ready
         log.debug("Starting CamelContext: {}", context.getName());
-        context.start();
+        if (isUseAdviceWith()) {
+                log.info("Skipping starting CamelContext as isUseAdviceWith is set to true.");
+        } else {
+                context.start();
+        }
     }
 
     /**


[2/9] camel git commit: Fixed CS

Posted by da...@apache.org.
Fixed CS


Project: http://git-wip-us.apache.org/repos/asf/camel/repo
Commit: http://git-wip-us.apache.org/repos/asf/camel/commit/1edc5fad
Tree: http://git-wip-us.apache.org/repos/asf/camel/tree/1edc5fad
Diff: http://git-wip-us.apache.org/repos/asf/camel/diff/1edc5fad

Branch: refs/heads/master
Commit: 1edc5fad3e32034af746dfb2a0284bfd38e2f866
Parents: dd4ba92
Author: Claus Ibsen <da...@apache.org>
Authored: Thu Jun 29 12:57:03 2017 +0200
Committer: Claus Ibsen <da...@apache.org>
Committed: Thu Jun 29 12:57:03 2017 +0200

----------------------------------------------------------------------
 .../apache/camel/test/blueprint/CamelBlueprintTestSupport.java   | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/camel/blob/1edc5fad/components/camel-test-blueprint/src/main/java/org/apache/camel/test/blueprint/CamelBlueprintTestSupport.java
----------------------------------------------------------------------
diff --git a/components/camel-test-blueprint/src/main/java/org/apache/camel/test/blueprint/CamelBlueprintTestSupport.java b/components/camel-test-blueprint/src/main/java/org/apache/camel/test/blueprint/CamelBlueprintTestSupport.java
index cddfaea..5e5cbab 100644
--- a/components/camel-test-blueprint/src/main/java/org/apache/camel/test/blueprint/CamelBlueprintTestSupport.java
+++ b/components/camel-test-blueprint/src/main/java/org/apache/camel/test/blueprint/CamelBlueprintTestSupport.java
@@ -249,9 +249,9 @@ public abstract class CamelBlueprintTestSupport extends CamelTestSupport {
         // start context when we are ready
         log.debug("Starting CamelContext: {}", context.getName());
         if (isUseAdviceWith()) {
-                log.info("Skipping starting CamelContext as isUseAdviceWith is set to true.");
+            log.info("Skipping starting CamelContext as isUseAdviceWith is set to true.");
         } else {
-                context.start();
+            context.start();
         }
     }
 


[3/9] camel git commit: CAMEL-11477: Can not override isUseAdviceWith in CamelBlueprintTestSupport

Posted by da...@apache.org.
CAMEL-11477: Can not override isUseAdviceWith in CamelBlueprintTestSupport


Project: http://git-wip-us.apache.org/repos/asf/camel/repo
Commit: http://git-wip-us.apache.org/repos/asf/camel/commit/35f172e6
Tree: http://git-wip-us.apache.org/repos/asf/camel/tree/35f172e6
Diff: http://git-wip-us.apache.org/repos/asf/camel/diff/35f172e6

Branch: refs/heads/master
Commit: 35f172e69382c148d807d518b92575601ba8f521
Parents: 1edc5fa
Author: Claus Ibsen <da...@apache.org>
Authored: Thu Jun 29 13:01:26 2017 +0200
Committer: Claus Ibsen <da...@apache.org>
Committed: Thu Jun 29 13:01:26 2017 +0200

----------------------------------------------------------------------
 .../blueprint/SimpleWeaveAddMockLastTest.java   | 50 ++++++++++++++++++++
 .../blueprint/SimpleWeaveAddMockLastTest.xml    | 38 +++++++++++++++
 2 files changed, 88 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/camel/blob/35f172e6/components/camel-test-blueprint/src/test/java/org/apache/camel/test/blueprint/SimpleWeaveAddMockLastTest.java
----------------------------------------------------------------------
diff --git a/components/camel-test-blueprint/src/test/java/org/apache/camel/test/blueprint/SimpleWeaveAddMockLastTest.java b/components/camel-test-blueprint/src/test/java/org/apache/camel/test/blueprint/SimpleWeaveAddMockLastTest.java
new file mode 100644
index 0000000..ddbeee2
--- /dev/null
+++ b/components/camel-test-blueprint/src/test/java/org/apache/camel/test/blueprint/SimpleWeaveAddMockLastTest.java
@@ -0,0 +1,50 @@
+/**
+ * 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.test.blueprint;
+
+import org.apache.camel.builder.AdviceWithRouteBuilder;
+import org.junit.Test;
+
+public class SimpleWeaveAddMockLastTest extends CamelBlueprintTestSupport {
+
+    @Override
+    protected String getBlueprintDescriptor() {
+        return "org/apache/camel/test/blueprint/SimpleWeaveAddMockLastTest.xml";
+    }
+
+    public boolean isUseAdviceWith() {
+        return true;
+    }
+
+    @Test
+    public void testWeaveAddMockLast() throws Exception {
+        context.getRouteDefinitions().get(0).adviceWith(context, new AdviceWithRouteBuilder() {
+            @Override
+            public void configure() throws Exception {
+                weaveAddLast().to("mock:result");
+            }
+        });
+        context.start();
+
+        getMockEndpoint("mock:result").expectedBodiesReceived("Bye Camel");
+
+        template.sendBody("seda:start", "Camel");
+
+        assertMockEndpointsSatisfied();
+    }
+
+}

http://git-wip-us.apache.org/repos/asf/camel/blob/35f172e6/components/camel-test-blueprint/src/test/resources/org/apache/camel/test/blueprint/SimpleWeaveAddMockLastTest.xml
----------------------------------------------------------------------
diff --git a/components/camel-test-blueprint/src/test/resources/org/apache/camel/test/blueprint/SimpleWeaveAddMockLastTest.xml b/components/camel-test-blueprint/src/test/resources/org/apache/camel/test/blueprint/SimpleWeaveAddMockLastTest.xml
new file mode 100644
index 0000000..ba8188a
--- /dev/null
+++ b/components/camel-test-blueprint/src/test/resources/org/apache/camel/test/blueprint/SimpleWeaveAddMockLastTest.xml
@@ -0,0 +1,38 @@
+<?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.
+
+-->
+<blueprint xmlns="http://www.osgi.org/xmlns/blueprint/v1.0.0"
+           xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+           xsi:schemaLocation="
+             http://www.osgi.org/xmlns/blueprint/v1.0.0 https://www.osgi.org/xmlns/blueprint/v1.0.0/blueprint.xsd">
+
+  <camelContext xmlns="http://camel.apache.org/schema/blueprint">
+
+    <route>
+      <from uri="seda:start"/>
+      <transform>
+        <simple>Bye ${body}</simple>
+      </transform>
+      <to uri="seda:queue"/>
+    </route>
+
+  </camelContext>
+
+</blueprint>
+


[5/9] camel git commit: Fixed CS

Posted by da...@apache.org.
Fixed CS


Project: http://git-wip-us.apache.org/repos/asf/camel/repo
Commit: http://git-wip-us.apache.org/repos/asf/camel/commit/b8c23d17
Tree: http://git-wip-us.apache.org/repos/asf/camel/tree/b8c23d17
Diff: http://git-wip-us.apache.org/repos/asf/camel/diff/b8c23d17

Branch: refs/heads/camel-2.19.x
Commit: b8c23d1712f5ddd184002d4e33063648f50ac656
Parents: 83b102b
Author: Claus Ibsen <da...@apache.org>
Authored: Thu Jun 29 12:57:03 2017 +0200
Committer: Claus Ibsen <da...@apache.org>
Committed: Thu Jun 29 13:08:59 2017 +0200

----------------------------------------------------------------------
 .../apache/camel/test/blueprint/CamelBlueprintTestSupport.java   | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/camel/blob/b8c23d17/components/camel-test-blueprint/src/main/java/org/apache/camel/test/blueprint/CamelBlueprintTestSupport.java
----------------------------------------------------------------------
diff --git a/components/camel-test-blueprint/src/main/java/org/apache/camel/test/blueprint/CamelBlueprintTestSupport.java b/components/camel-test-blueprint/src/main/java/org/apache/camel/test/blueprint/CamelBlueprintTestSupport.java
index cddfaea..5e5cbab 100644
--- a/components/camel-test-blueprint/src/main/java/org/apache/camel/test/blueprint/CamelBlueprintTestSupport.java
+++ b/components/camel-test-blueprint/src/main/java/org/apache/camel/test/blueprint/CamelBlueprintTestSupport.java
@@ -249,9 +249,9 @@ public abstract class CamelBlueprintTestSupport extends CamelTestSupport {
         // start context when we are ready
         log.debug("Starting CamelContext: {}", context.getName());
         if (isUseAdviceWith()) {
-                log.info("Skipping starting CamelContext as isUseAdviceWith is set to true.");
+            log.info("Skipping starting CamelContext as isUseAdviceWith is set to true.");
         } else {
-                context.start();
+            context.start();
         }
     }
 


[4/9] camel git commit: CAMEL-11477: Can not override isUseAdviceWith in CamelBlueprintTestSupport

Posted by da...@apache.org.
CAMEL-11477: Can not override isUseAdviceWith in CamelBlueprintTestSupport


Project: http://git-wip-us.apache.org/repos/asf/camel/repo
Commit: http://git-wip-us.apache.org/repos/asf/camel/commit/83b102bc
Tree: http://git-wip-us.apache.org/repos/asf/camel/tree/83b102bc
Diff: http://git-wip-us.apache.org/repos/asf/camel/diff/83b102bc

Branch: refs/heads/camel-2.19.x
Commit: 83b102bc4f05de62fbb40a2496c50b1546dd93b9
Parents: a202960
Author: Saravanakumar Selvaraj <ss...@ssaravan.pnq.csb>
Authored: Thu Jun 29 10:33:43 2017 +0530
Committer: Claus Ibsen <da...@apache.org>
Committed: Thu Jun 29 13:08:52 2017 +0200

----------------------------------------------------------------------
 .../apache/camel/test/blueprint/CamelBlueprintTestSupport.java | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/camel/blob/83b102bc/components/camel-test-blueprint/src/main/java/org/apache/camel/test/blueprint/CamelBlueprintTestSupport.java
----------------------------------------------------------------------
diff --git a/components/camel-test-blueprint/src/main/java/org/apache/camel/test/blueprint/CamelBlueprintTestSupport.java b/components/camel-test-blueprint/src/main/java/org/apache/camel/test/blueprint/CamelBlueprintTestSupport.java
index 566ccaa..cddfaea 100644
--- a/components/camel-test-blueprint/src/main/java/org/apache/camel/test/blueprint/CamelBlueprintTestSupport.java
+++ b/components/camel-test-blueprint/src/main/java/org/apache/camel/test/blueprint/CamelBlueprintTestSupport.java
@@ -248,7 +248,11 @@ public abstract class CamelBlueprintTestSupport extends CamelTestSupport {
 
         // start context when we are ready
         log.debug("Starting CamelContext: {}", context.getName());
-        context.start();
+        if (isUseAdviceWith()) {
+                log.info("Skipping starting CamelContext as isUseAdviceWith is set to true.");
+        } else {
+                context.start();
+        }
     }
 
     /**


[9/9] camel git commit: CAMEL-11477: Can not override isUseAdviceWith in CamelBlueprintTestSupport

Posted by da...@apache.org.
CAMEL-11477: Can not override isUseAdviceWith in CamelBlueprintTestSupport


Project: http://git-wip-us.apache.org/repos/asf/camel/repo
Commit: http://git-wip-us.apache.org/repos/asf/camel/commit/e0c5b148
Tree: http://git-wip-us.apache.org/repos/asf/camel/tree/e0c5b148
Diff: http://git-wip-us.apache.org/repos/asf/camel/diff/e0c5b148

Branch: refs/heads/camel-2.18.x
Commit: e0c5b1483a03caef33bb65c21bb4487c69952a25
Parents: 044083e
Author: Claus Ibsen <da...@apache.org>
Authored: Thu Jun 29 13:01:26 2017 +0200
Committer: Claus Ibsen <da...@apache.org>
Committed: Thu Jun 29 13:31:13 2017 +0200

----------------------------------------------------------------------
 .../blueprint/SimpleWeaveAddMockLastTest.java   | 50 ++++++++++++++++++++
 .../blueprint/SimpleWeaveAddMockLastTest.xml    | 38 +++++++++++++++
 2 files changed, 88 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/camel/blob/e0c5b148/components/camel-test-blueprint/src/test/java/org/apache/camel/test/blueprint/SimpleWeaveAddMockLastTest.java
----------------------------------------------------------------------
diff --git a/components/camel-test-blueprint/src/test/java/org/apache/camel/test/blueprint/SimpleWeaveAddMockLastTest.java b/components/camel-test-blueprint/src/test/java/org/apache/camel/test/blueprint/SimpleWeaveAddMockLastTest.java
new file mode 100644
index 0000000..ddbeee2
--- /dev/null
+++ b/components/camel-test-blueprint/src/test/java/org/apache/camel/test/blueprint/SimpleWeaveAddMockLastTest.java
@@ -0,0 +1,50 @@
+/**
+ * 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.test.blueprint;
+
+import org.apache.camel.builder.AdviceWithRouteBuilder;
+import org.junit.Test;
+
+public class SimpleWeaveAddMockLastTest extends CamelBlueprintTestSupport {
+
+    @Override
+    protected String getBlueprintDescriptor() {
+        return "org/apache/camel/test/blueprint/SimpleWeaveAddMockLastTest.xml";
+    }
+
+    public boolean isUseAdviceWith() {
+        return true;
+    }
+
+    @Test
+    public void testWeaveAddMockLast() throws Exception {
+        context.getRouteDefinitions().get(0).adviceWith(context, new AdviceWithRouteBuilder() {
+            @Override
+            public void configure() throws Exception {
+                weaveAddLast().to("mock:result");
+            }
+        });
+        context.start();
+
+        getMockEndpoint("mock:result").expectedBodiesReceived("Bye Camel");
+
+        template.sendBody("seda:start", "Camel");
+
+        assertMockEndpointsSatisfied();
+    }
+
+}

http://git-wip-us.apache.org/repos/asf/camel/blob/e0c5b148/components/camel-test-blueprint/src/test/resources/org/apache/camel/test/blueprint/SimpleWeaveAddMockLastTest.xml
----------------------------------------------------------------------
diff --git a/components/camel-test-blueprint/src/test/resources/org/apache/camel/test/blueprint/SimpleWeaveAddMockLastTest.xml b/components/camel-test-blueprint/src/test/resources/org/apache/camel/test/blueprint/SimpleWeaveAddMockLastTest.xml
new file mode 100644
index 0000000..ba8188a
--- /dev/null
+++ b/components/camel-test-blueprint/src/test/resources/org/apache/camel/test/blueprint/SimpleWeaveAddMockLastTest.xml
@@ -0,0 +1,38 @@
+<?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.
+
+-->
+<blueprint xmlns="http://www.osgi.org/xmlns/blueprint/v1.0.0"
+           xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+           xsi:schemaLocation="
+             http://www.osgi.org/xmlns/blueprint/v1.0.0 https://www.osgi.org/xmlns/blueprint/v1.0.0/blueprint.xsd">
+
+  <camelContext xmlns="http://camel.apache.org/schema/blueprint">
+
+    <route>
+      <from uri="seda:start"/>
+      <transform>
+        <simple>Bye ${body}</simple>
+      </transform>
+      <to uri="seda:queue"/>
+    </route>
+
+  </camelContext>
+
+</blueprint>
+


[7/9] camel git commit: CAMEL-11477: Can not override isUseAdviceWith in CamelBlueprintTestSupport

Posted by da...@apache.org.
CAMEL-11477: Can not override isUseAdviceWith in CamelBlueprintTestSupport


Project: http://git-wip-us.apache.org/repos/asf/camel/repo
Commit: http://git-wip-us.apache.org/repos/asf/camel/commit/abc3087a
Tree: http://git-wip-us.apache.org/repos/asf/camel/tree/abc3087a
Diff: http://git-wip-us.apache.org/repos/asf/camel/diff/abc3087a

Branch: refs/heads/camel-2.18.x
Commit: abc3087aa356e52d5966a8434b5289bf07909ad8
Parents: e010a3f
Author: Saravanakumar Selvaraj <ss...@ssaravan.pnq.csb>
Authored: Thu Jun 29 10:33:43 2017 +0530
Committer: Claus Ibsen <da...@apache.org>
Committed: Thu Jun 29 13:30:59 2017 +0200

----------------------------------------------------------------------
 .../apache/camel/test/blueprint/CamelBlueprintTestSupport.java | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/camel/blob/abc3087a/components/camel-test-blueprint/src/main/java/org/apache/camel/test/blueprint/CamelBlueprintTestSupport.java
----------------------------------------------------------------------
diff --git a/components/camel-test-blueprint/src/main/java/org/apache/camel/test/blueprint/CamelBlueprintTestSupport.java b/components/camel-test-blueprint/src/main/java/org/apache/camel/test/blueprint/CamelBlueprintTestSupport.java
index 60348f6..686854c 100644
--- a/components/camel-test-blueprint/src/main/java/org/apache/camel/test/blueprint/CamelBlueprintTestSupport.java
+++ b/components/camel-test-blueprint/src/main/java/org/apache/camel/test/blueprint/CamelBlueprintTestSupport.java
@@ -248,7 +248,11 @@ public abstract class CamelBlueprintTestSupport extends CamelTestSupport {
 
         // start context when we are ready
         log.debug("Starting CamelContext: {}", context.getName());
-        context.start();
+        if (isUseAdviceWith()) {
+                log.info("Skipping starting CamelContext as isUseAdviceWith is set to true.");
+        } else {
+                context.start();
+        }
     }
 
     /**


[6/9] camel git commit: CAMEL-11477: Can not override isUseAdviceWith in CamelBlueprintTestSupport

Posted by da...@apache.org.
CAMEL-11477: Can not override isUseAdviceWith in CamelBlueprintTestSupport


Project: http://git-wip-us.apache.org/repos/asf/camel/repo
Commit: http://git-wip-us.apache.org/repos/asf/camel/commit/961d4f69
Tree: http://git-wip-us.apache.org/repos/asf/camel/tree/961d4f69
Diff: http://git-wip-us.apache.org/repos/asf/camel/diff/961d4f69

Branch: refs/heads/camel-2.19.x
Commit: 961d4f69348f8e832e772cf0efe23b9d0c8a0a94
Parents: b8c23d1
Author: Claus Ibsen <da...@apache.org>
Authored: Thu Jun 29 13:01:26 2017 +0200
Committer: Claus Ibsen <da...@apache.org>
Committed: Thu Jun 29 13:09:05 2017 +0200

----------------------------------------------------------------------
 .../blueprint/SimpleWeaveAddMockLastTest.java   | 50 ++++++++++++++++++++
 .../blueprint/SimpleWeaveAddMockLastTest.xml    | 38 +++++++++++++++
 2 files changed, 88 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/camel/blob/961d4f69/components/camel-test-blueprint/src/test/java/org/apache/camel/test/blueprint/SimpleWeaveAddMockLastTest.java
----------------------------------------------------------------------
diff --git a/components/camel-test-blueprint/src/test/java/org/apache/camel/test/blueprint/SimpleWeaveAddMockLastTest.java b/components/camel-test-blueprint/src/test/java/org/apache/camel/test/blueprint/SimpleWeaveAddMockLastTest.java
new file mode 100644
index 0000000..ddbeee2
--- /dev/null
+++ b/components/camel-test-blueprint/src/test/java/org/apache/camel/test/blueprint/SimpleWeaveAddMockLastTest.java
@@ -0,0 +1,50 @@
+/**
+ * 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.test.blueprint;
+
+import org.apache.camel.builder.AdviceWithRouteBuilder;
+import org.junit.Test;
+
+public class SimpleWeaveAddMockLastTest extends CamelBlueprintTestSupport {
+
+    @Override
+    protected String getBlueprintDescriptor() {
+        return "org/apache/camel/test/blueprint/SimpleWeaveAddMockLastTest.xml";
+    }
+
+    public boolean isUseAdviceWith() {
+        return true;
+    }
+
+    @Test
+    public void testWeaveAddMockLast() throws Exception {
+        context.getRouteDefinitions().get(0).adviceWith(context, new AdviceWithRouteBuilder() {
+            @Override
+            public void configure() throws Exception {
+                weaveAddLast().to("mock:result");
+            }
+        });
+        context.start();
+
+        getMockEndpoint("mock:result").expectedBodiesReceived("Bye Camel");
+
+        template.sendBody("seda:start", "Camel");
+
+        assertMockEndpointsSatisfied();
+    }
+
+}

http://git-wip-us.apache.org/repos/asf/camel/blob/961d4f69/components/camel-test-blueprint/src/test/resources/org/apache/camel/test/blueprint/SimpleWeaveAddMockLastTest.xml
----------------------------------------------------------------------
diff --git a/components/camel-test-blueprint/src/test/resources/org/apache/camel/test/blueprint/SimpleWeaveAddMockLastTest.xml b/components/camel-test-blueprint/src/test/resources/org/apache/camel/test/blueprint/SimpleWeaveAddMockLastTest.xml
new file mode 100644
index 0000000..ba8188a
--- /dev/null
+++ b/components/camel-test-blueprint/src/test/resources/org/apache/camel/test/blueprint/SimpleWeaveAddMockLastTest.xml
@@ -0,0 +1,38 @@
+<?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.
+
+-->
+<blueprint xmlns="http://www.osgi.org/xmlns/blueprint/v1.0.0"
+           xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+           xsi:schemaLocation="
+             http://www.osgi.org/xmlns/blueprint/v1.0.0 https://www.osgi.org/xmlns/blueprint/v1.0.0/blueprint.xsd">
+
+  <camelContext xmlns="http://camel.apache.org/schema/blueprint">
+
+    <route>
+      <from uri="seda:start"/>
+      <transform>
+        <simple>Bye ${body}</simple>
+      </transform>
+      <to uri="seda:queue"/>
+    </route>
+
+  </camelContext>
+
+</blueprint>
+


[8/9] camel git commit: Fixed CS

Posted by da...@apache.org.
Fixed CS


Project: http://git-wip-us.apache.org/repos/asf/camel/repo
Commit: http://git-wip-us.apache.org/repos/asf/camel/commit/044083e6
Tree: http://git-wip-us.apache.org/repos/asf/camel/tree/044083e6
Diff: http://git-wip-us.apache.org/repos/asf/camel/diff/044083e6

Branch: refs/heads/camel-2.18.x
Commit: 044083e6049d68d6238dc5d39a80d0fd17597f79
Parents: abc3087
Author: Claus Ibsen <da...@apache.org>
Authored: Thu Jun 29 12:57:03 2017 +0200
Committer: Claus Ibsen <da...@apache.org>
Committed: Thu Jun 29 13:31:06 2017 +0200

----------------------------------------------------------------------
 .../apache/camel/test/blueprint/CamelBlueprintTestSupport.java   | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/camel/blob/044083e6/components/camel-test-blueprint/src/main/java/org/apache/camel/test/blueprint/CamelBlueprintTestSupport.java
----------------------------------------------------------------------
diff --git a/components/camel-test-blueprint/src/main/java/org/apache/camel/test/blueprint/CamelBlueprintTestSupport.java b/components/camel-test-blueprint/src/main/java/org/apache/camel/test/blueprint/CamelBlueprintTestSupport.java
index 686854c..5d7eaed 100644
--- a/components/camel-test-blueprint/src/main/java/org/apache/camel/test/blueprint/CamelBlueprintTestSupport.java
+++ b/components/camel-test-blueprint/src/main/java/org/apache/camel/test/blueprint/CamelBlueprintTestSupport.java
@@ -249,9 +249,9 @@ public abstract class CamelBlueprintTestSupport extends CamelTestSupport {
         // start context when we are ready
         log.debug("Starting CamelContext: {}", context.getName());
         if (isUseAdviceWith()) {
-                log.info("Skipping starting CamelContext as isUseAdviceWith is set to true.");
+            log.info("Skipping starting CamelContext as isUseAdviceWith is set to true.");
         } else {
-                context.start();
+            context.start();
         }
     }