You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@camel.apache.org by ni...@apache.org on 2016/01/18 04:07:22 UTC

[3/3] camel git commit: Using the port property in NettyHttpCompressTest

Using the port property in NettyHttpCompressTest

Conflicts:
	components/camel-netty4-http/src/test/java/org/apache/camel/component/netty4/http/NettyHttpCompressTest.java


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

Branch: refs/heads/camel-2.16.x
Commit: 30a9732f8c2c873df1a9554a40d08637e65e40d4
Parents: 34707b2
Author: Willem Jiang <wi...@gmail.com>
Authored: Mon Jan 18 09:13:52 2016 +0800
Committer: Willem Jiang <wi...@gmail.com>
Committed: Mon Jan 18 11:06:41 2016 +0800

----------------------------------------------------------------------
 .../component/netty4/http/NettyHttpCompressTest.java  | 14 +++++++-------
 1 file changed, 7 insertions(+), 7 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/camel/blob/30a9732f/components/camel-netty4-http/src/test/java/org/apache/camel/component/netty4/http/NettyHttpCompressTest.java
----------------------------------------------------------------------
diff --git a/components/camel-netty4-http/src/test/java/org/apache/camel/component/netty4/http/NettyHttpCompressTest.java b/components/camel-netty4-http/src/test/java/org/apache/camel/component/netty4/http/NettyHttpCompressTest.java
index 1697c75..a0acb9f 100644
--- a/components/camel-netty4-http/src/test/java/org/apache/camel/component/netty4/http/NettyHttpCompressTest.java
+++ b/components/camel-netty4-http/src/test/java/org/apache/camel/component/netty4/http/NettyHttpCompressTest.java
@@ -30,7 +30,7 @@ import org.apache.camel.impl.JndiRegistry;
 import org.junit.Test;
 
 public class NettyHttpCompressTest extends BaseNettyTest {
-    
+
     // setup the decompress decoder here
     @Override
     protected JndiRegistry createRegistry() throws Exception {
@@ -40,22 +40,22 @@ public class NettyHttpCompressTest extends BaseNettyTest {
         registry.bind("myDecoders", decoders);
         return registry;
     }
-    
+
 
     @Test
     public void testContentType() throws Exception {
-        
+
         byte[] data = "Hello World".getBytes(Charset.forName("UTF-8"));
         Map<String, Object> headers = new HashMap<String, Object>();
         headers.put("content-type", "text/plain; charset=\"UTF-8\"");
         headers.put("Accept-Encoding", "compress, gzip");
-        String out = template.requestBodyAndHeaders("netty4-http:http://0.0.0.0:9001/foo?decoders=#myDecoders", data,
+        String out = template.requestBodyAndHeaders("netty4-http:http://localhost:{{port}}/foo?decoders=#myDecoders", data,
                 headers, String.class);
         // The decoded out has some space to clean up.
         assertEquals("Bye World", out.trim());
-        
 
-        
+
+
     }
 
     @Override
@@ -63,7 +63,7 @@ public class NettyHttpCompressTest extends BaseNettyTest {
         return new RouteBuilder() {
             @Override
             public void configure() throws Exception {
-                from("netty4-http:http://0.0.0.0:9001/foo?compression=true")
+                from("netty4-http:http://0.0.0.0:{{port}}/foo?compression=true")
                     .transform().constant("Bye World").setHeader("content-type").constant("text/plain; charset=\"UTF-8\"");
             }
         };