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 2016/12/08 16:34:02 UTC
[1/2] camel git commit: Polished test
Repository: camel
Updated Branches:
refs/heads/master 8743dd8ba -> f2dcfa45a
Polished test
Project: http://git-wip-us.apache.org/repos/asf/camel/repo
Commit: http://git-wip-us.apache.org/repos/asf/camel/commit/7ba05c98
Tree: http://git-wip-us.apache.org/repos/asf/camel/tree/7ba05c98
Diff: http://git-wip-us.apache.org/repos/asf/camel/diff/7ba05c98
Branch: refs/heads/master
Commit: 7ba05c98148a0712af674d6500ea91b2f526fc79
Parents: 8743dd8
Author: Claus Ibsen <da...@apache.org>
Authored: Thu Dec 8 17:29:53 2016 +0100
Committer: Claus Ibsen <da...@apache.org>
Committed: Thu Dec 8 17:29:53 2016 +0100
----------------------------------------------------------------------
.../http/NettyHttpProducerSessionTest.java | 23 ++++++--------------
1 file changed, 7 insertions(+), 16 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/camel/blob/7ba05c98/components/camel-netty4-http/src/test/java/org/apache/camel/component/netty4/http/NettyHttpProducerSessionTest.java
----------------------------------------------------------------------
diff --git a/components/camel-netty4-http/src/test/java/org/apache/camel/component/netty4/http/NettyHttpProducerSessionTest.java b/components/camel-netty4-http/src/test/java/org/apache/camel/component/netty4/http/NettyHttpProducerSessionTest.java
index b5f55d1..ae587bf 100644
--- a/components/camel-netty4-http/src/test/java/org/apache/camel/component/netty4/http/NettyHttpProducerSessionTest.java
+++ b/components/camel-netty4-http/src/test/java/org/apache/camel/component/netty4/http/NettyHttpProducerSessionTest.java
@@ -61,36 +61,27 @@ public class NettyHttpProducerSessionTest extends BaseNettyTest {
return jndiRegistry;
}
- private String getTestServerEndpointSessionUrl() {
- // session handling will not work for localhost
- return "http://127.0.0.1:" + getPort() + "/session";
- }
-
- private String getTestServerEndpointSessionUri() {
- return "jetty:" + getTestServerEndpointSessionUrl() + "?sessionSupport=true";
- }
-
@Override
protected RouteBuilder createRouteBuilder() throws Exception {
return new RouteBuilder() {
@Override
public void configure() throws Exception {
from("direct:start")
- .to("netty4-http:" + getTestServerEndpointSessionUrl())
- .to("netty4-http:" + getTestServerEndpointSessionUrl())
+ .toF("netty4-http:http://127.0.0.1:%d/session", getPort())
+ .toF("netty4-http:http://127.0.0.1:%d/session", getPort())
.to("mock:result");
from("direct:instance")
- .to("netty4-http:" + getTestServerEndpointSessionUrl() + "?cookieHandler=#instanceCookieHandler")
- .to("netty4-http:" + getTestServerEndpointSessionUrl() + "?cookieHandler=#instanceCookieHandler")
+ .toF("netty4-http:http://127.0.0.1:%d/session?cookieHandler=#instanceCookieHandler", getPort())
+ .toF("netty4-http:http://127.0.0.1:%d/session?cookieHandler=#instanceCookieHandler", getPort())
.to("mock:result");
from("direct:exchange")
- .to("netty4-http:" + getTestServerEndpointSessionUrl() + "?cookieHandler=#exchangeCookieHandler")
- .to("netty4-http:" + getTestServerEndpointSessionUrl() + "?cookieHandler=#exchangeCookieHandler")
+ .toF("netty4-http:http://127.0.0.1:%d/session?cookieHandler=#exchangeCookieHandler", getPort())
+ .toF("netty4-http:http://127.0.0.1:%d/session?cookieHandler=#exchangeCookieHandler", getPort())
.to("mock:result");
- from(getTestServerEndpointSessionUri())
+ fromF("jetty:http://127.0.0.1:%d/session?sessionSupport=true", getPort())
.process(new Processor() {
@Override
public void process(Exchange exchange) throws Exception {
[2/2] camel git commit: Add camel:validate
Posted by da...@apache.org.
Add camel:validate
Project: http://git-wip-us.apache.org/repos/asf/camel/repo
Commit: http://git-wip-us.apache.org/repos/asf/camel/commit/f2dcfa45
Tree: http://git-wip-us.apache.org/repos/asf/camel/tree/f2dcfa45
Diff: http://git-wip-us.apache.org/repos/asf/camel/diff/f2dcfa45
Branch: refs/heads/master
Commit: f2dcfa45a66bf0373cde2d76b9e77ff5adff98a9
Parents: 7ba05c9
Author: Claus Ibsen <da...@apache.org>
Authored: Thu Dec 8 17:32:00 2016 +0100
Committer: Claus Ibsen <da...@apache.org>
Committed: Thu Dec 8 17:33:48 2016 +0100
----------------------------------------------------------------------
examples/pom.xml | 13 +++++++++++++
tests/camel-itest/pom.xml | 19 +++++++++++++++++++
2 files changed, 32 insertions(+)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/camel/blob/f2dcfa45/examples/pom.xml
----------------------------------------------------------------------
diff --git a/examples/pom.xml b/examples/pom.xml
index 9aeaffc..0cebc70 100644
--- a/examples/pom.xml
+++ b/examples/pom.xml
@@ -139,6 +139,19 @@
</executions>
</plugin>
+ <!-- to validate Camel endpoints: mvn camel:validate -->
+ <plugin>
+ <groupId>org.apache.camel</groupId>
+ <artifactId>camel-maven-plugin</artifactId>
+ <version>${project.version}</version>
+ <configuration>
+ <failOnError>false</failOnError>
+ <includeTest>true</includeTest>
+ <includeXml>true</includeXml>
+ <ignoreLenientProperties>false</ignoreLenientProperties>
+ </configuration>
+ </plugin>
+
<plugin>
<artifactId>maven-surefire-plugin</artifactId>
<configuration>
http://git-wip-us.apache.org/repos/asf/camel/blob/f2dcfa45/tests/camel-itest/pom.xml
----------------------------------------------------------------------
diff --git a/tests/camel-itest/pom.xml b/tests/camel-itest/pom.xml
index d2aba81..97fe8b1 100644
--- a/tests/camel-itest/pom.xml
+++ b/tests/camel-itest/pom.xml
@@ -47,6 +47,11 @@
<dependencies>
<dependency>
<groupId>org.apache.camel</groupId>
+ <artifactId>camel-core</artifactId>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.camel</groupId>
<artifactId>camel-jms</artifactId>
<scope>test</scope>
</dependency>
@@ -413,6 +418,20 @@
<build>
<plugins>
+
+ <!-- to validate Camel endpoints: mvn camel:validate -->
+ <plugin>
+ <groupId>org.apache.camel</groupId>
+ <artifactId>camel-maven-plugin</artifactId>
+ <version>${project.version}</version>
+ <configuration>
+ <failOnError>false</failOnError>
+ <includeTest>true</includeTest>
+ <includeXml>true</includeXml>
+ <ignoreLenientProperties>false</ignoreLenientProperties>
+ </configuration>
+ </plugin>
+
<plugin>
<artifactId>maven-surefire-plugin</artifactId>
<configuration>