cxf-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From dk...@apache.org
Subject svn commit: r1167352 - in /cxf/trunk/systests/jaxws/src/test/java/org/apache/cxf/systest/dispatch: DispatchClientServerTest.java resources/GreetMe1WDocLiteralReq2.xml
Date Fri, 09 Sep 2011 20:35:17 GMT
Author: dkulp
Date: Fri Sep  9 20:35:17 2011
New Revision: 1167352

URL: http://svn.apache.org/viewvc?rev=1167352&view=rev
Log:
Added a test to show the need for CXF-3796

Added:
    cxf/trunk/systests/jaxws/src/test/java/org/apache/cxf/systest/dispatch/resources/GreetMe1WDocLiteralReq2.xml
  (with props)
Modified:
    cxf/trunk/systests/jaxws/src/test/java/org/apache/cxf/systest/dispatch/DispatchClientServerTest.java

Modified: cxf/trunk/systests/jaxws/src/test/java/org/apache/cxf/systest/dispatch/DispatchClientServerTest.java
URL: http://svn.apache.org/viewvc/cxf/trunk/systests/jaxws/src/test/java/org/apache/cxf/systest/dispatch/DispatchClientServerTest.java?rev=1167352&r1=1167351&r2=1167352&view=diff
==============================================================================
--- cxf/trunk/systests/jaxws/src/test/java/org/apache/cxf/systest/dispatch/DispatchClientServerTest.java
(original)
+++ cxf/trunk/systests/jaxws/src/test/java/org/apache/cxf/systest/dispatch/DispatchClientServerTest.java
Fri Sep  9 20:35:17 2011
@@ -74,6 +74,7 @@ import org.apache.hello_world_soap_http.
 import org.apache.hello_world_soap_http.types.GreetMeLater;
 import org.apache.hello_world_soap_http.types.GreetMeResponse;
 import org.junit.BeforeClass;
+import org.junit.Ignore;
 import org.junit.Test;
 
 
@@ -223,6 +224,28 @@ public class DispatchClientServerTest ex
         
     }
     @Test
+    @Ignore
+    public void testSOAPMessageInvokeToOneWay() throws Exception {
+        SOAPService service = new SOAPService(null, SERVICE_NAME);
+        service.addPort(PORT_NAME, SOAPBinding.SOAP11HTTP_BINDING,
+                        "http://localhost:" + greeterPort 
+                        + "/SOAPDispatchService/SoapDispatchPort");
+        assertNotNull(service);
+        
+        Dispatch<SOAPMessage> disp = service
+            .createDispatch(PORT_NAME, SOAPMessage.class, Service.Mode.MESSAGE);
+
+        //message is "one way", but there really isn't a way for us to know that
+        //as we don't have a wsdl or other source of operation information to
+        //compare the payload to.
+        InputStream is1 = getClass().getResourceAsStream("resources/GreetMe1WDocLiteralReq2.xml");
+        SOAPMessage soapReqMsg1 = MessageFactory.newInstance().createMessage(null, is1);
+        assertNotNull(soapReqMsg1);
+        
+        //we'll just call invoke
+        disp.invoke(soapReqMsg1);
+    }
+    @Test
     public void testSOAPMessage() throws Exception {
 
         URL wsdl = getClass().getResource("/wsdl/hello_world.wsdl");
@@ -250,7 +273,7 @@ public class DispatchClientServerTest ex
             .getTextContent().trim());
 
         // Test oneway
-        InputStream is1 = getClass().getResourceAsStream("resources/GreetMeDocLiteralReq1.xml");
+        InputStream is1 = getClass().getResourceAsStream("resources/GreetMe1WDocLiteralReq2.xml");
         SOAPMessage soapReqMsg1 = MessageFactory.newInstance().createMessage(null, is1);
         assertNotNull(soapReqMsg1);
         disp.invokeOneWay(soapReqMsg1);

Added: cxf/trunk/systests/jaxws/src/test/java/org/apache/cxf/systest/dispatch/resources/GreetMe1WDocLiteralReq2.xml
URL: http://svn.apache.org/viewvc/cxf/trunk/systests/jaxws/src/test/java/org/apache/cxf/systest/dispatch/resources/GreetMe1WDocLiteralReq2.xml?rev=1167352&view=auto
==============================================================================
--- cxf/trunk/systests/jaxws/src/test/java/org/apache/cxf/systest/dispatch/resources/GreetMe1WDocLiteralReq2.xml
(added)
+++ cxf/trunk/systests/jaxws/src/test/java/org/apache/cxf/systest/dispatch/resources/GreetMe1WDocLiteralReq2.xml
Fri Sep  9 20:35:17 2011
@@ -0,0 +1,20 @@
+<?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.
+-->
+<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xs="http://www.w3.org/2001/XMLSchema"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><SOAP-ENV:Body><ns4:greetMeOneWay
xmlns:ns4="http://apache.org/hello_world_soap_http/types"><ns4:requestType>TestSOAPInputMessage2</ns4:requestType></ns4:greetMeOneWay></SOAP-ENV:Body></SOAP-ENV:Envelope>

Propchange: cxf/trunk/systests/jaxws/src/test/java/org/apache/cxf/systest/dispatch/resources/GreetMe1WDocLiteralReq2.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: cxf/trunk/systests/jaxws/src/test/java/org/apache/cxf/systest/dispatch/resources/GreetMe1WDocLiteralReq2.xml
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Propchange: cxf/trunk/systests/jaxws/src/test/java/org/apache/cxf/systest/dispatch/resources/GreetMe1WDocLiteralReq2.xml
------------------------------------------------------------------------------
    svn:mime-type = text/xml



Mime
View raw message