cxf-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From serg...@apache.org
Subject svn commit: r1550128 - in /cxf/branches/2.7.x-fixes: ./ systests/jaxrs/src/test/java/org/apache/cxf/systest/jaxrs/JAXRSClientServerBookTest.java
Date Wed, 11 Dec 2013 12:47:16 GMT
Author: sergeyb
Date: Wed Dec 11 12:47:16 2013
New Revision: 1550128

URL: http://svn.apache.org/r1550128
Log:
Merged revisions 1550127 via svnmerge from 
https://svn.apache.org/repos/asf/cxf/trunk

........
  r1550127 | sergeyb | 2013-12-11 12:44:47 +0000 (Wed, 11 Dec 2013) | 1 line
  
  [CXF-5447] Adding a test depending on the empty request property
........

Modified:
    cxf/branches/2.7.x-fixes/   (props changed)
    cxf/branches/2.7.x-fixes/systests/jaxrs/src/test/java/org/apache/cxf/systest/jaxrs/JAXRSClientServerBookTest.java

Propchange: cxf/branches/2.7.x-fixes/
------------------------------------------------------------------------------
  Merged /cxf/trunk:r1550127

Propchange: cxf/branches/2.7.x-fixes/
------------------------------------------------------------------------------
Binary property 'svnmerge-integrated' - no diff available.

Modified: cxf/branches/2.7.x-fixes/systests/jaxrs/src/test/java/org/apache/cxf/systest/jaxrs/JAXRSClientServerBookTest.java
URL: http://svn.apache.org/viewvc/cxf/branches/2.7.x-fixes/systests/jaxrs/src/test/java/org/apache/cxf/systest/jaxrs/JAXRSClientServerBookTest.java?rev=1550128&r1=1550127&r2=1550128&view=diff
==============================================================================
--- cxf/branches/2.7.x-fixes/systests/jaxrs/src/test/java/org/apache/cxf/systest/jaxrs/JAXRSClientServerBookTest.java
(original)
+++ cxf/branches/2.7.x-fixes/systests/jaxrs/src/test/java/org/apache/cxf/systest/jaxrs/JAXRSClientServerBookTest.java
Wed Dec 11 12:47:16 2013
@@ -19,6 +19,7 @@
 
 package org.apache.cxf.systest.jaxrs;
 
+import java.io.ByteArrayInputStream;
 import java.io.File;
 import java.io.InputStream;
 import java.net.HttpURLConnection;
@@ -175,6 +176,16 @@ public class JAXRSClientServerBookTest e
     }
     
     @Test
+    public void testPostEmptyFormAsInStream() throws Exception {
+        String address = "http://localhost:" + PORT + "/bookstore/emptyform";
+        WebClient wc = WebClient.create(address);
+        WebClient.getConfig(wc).getRequestContext().put("org.apache.cxf.empty.request", true);
+        wc.type(MediaType.APPLICATION_FORM_URLENCODED);
+        Response r = wc.post(new ByteArrayInputStream("".getBytes()));
+        assertEquals("empty form", r.readEntity(String.class));
+    }
+    
+    @Test
     public void testGetBookDescriptionHttpResponse() throws Exception {
         String address = "http://localhost:" + PORT + "/bookstore/httpresponse";
         WebClient wc = WebClient.create(address);



Mime
View raw message