cxf-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From e..@apache.org
Subject svn commit: r527424 - in /incubator/cxf/trunk/tools/javato: pom.xml src/test/java/org/apache/cxf/tools/java2wsdl/processor/internal/jaxws/JaxwsServiceBuilderTest.java
Date Wed, 11 Apr 2007 09:08:03 GMT
Author: ema
Date: Wed Apr 11 02:07:59 2007
New Revision: 527424

URL: http://svn.apache.org/viewvc?view=rev&rev=527424
Log:
Added more test case for using runtime to generate wsdl  

Modified:
    incubator/cxf/trunk/tools/javato/pom.xml
    incubator/cxf/trunk/tools/javato/src/test/java/org/apache/cxf/tools/java2wsdl/processor/internal/jaxws/JaxwsServiceBuilderTest.java

Modified: incubator/cxf/trunk/tools/javato/pom.xml
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/tools/javato/pom.xml?view=diff&rev=527424&r1=527423&r2=527424
==============================================================================
--- incubator/cxf/trunk/tools/javato/pom.xml (original)
+++ incubator/cxf/trunk/tools/javato/pom.xml Wed Apr 11 02:07:59 2007
@@ -141,6 +141,22 @@
 				<wsdlOption>
 				    <wsdl>${basedir}/src/test/resources/java2wsdl_wsdl/hello_world_async.wsdl</wsdl>
 				</wsdlOption>
+				<wsdlOption>
+				    <wsdl>${basedir}/src/test/resources/java2wsdl_wsdl/doc_wrapped_simple.wsdl</wsdl>
+				</wsdlOption>
+				<wsdlOption>
+				     <wsdl>${basedir}/src/test/resources/java2wsdl_wsdl/hello_world_doc_lit.wsdl</wsdl>
+				</wsdlOption>
+				<wsdlOption>
+				     <wsdl>${basedir}/src/test/resources/java2wsdl_wsdl/hello_world_doc_wrapped_bare.wsdl</wsdl>
+				</wsdlOption>
+				<wsdlOption>
+				     <wsdl>${basedir}/src/test/resources/java2wsdl_wsdl/hello_world_rpc_lit.wsdl</wsdl>
+				</wsdlOption>
+				<wsdlOption>
+				      <wsdl>${basedir}/src/test/resources/java2wsdl_wsdl/hello_world_soap12.wsdl</wsdl>
+				</wsdlOption>
+				
 			    </wsdlOptions>
 			</configuration>
 			<goals>

Modified: incubator/cxf/trunk/tools/javato/src/test/java/org/apache/cxf/tools/java2wsdl/processor/internal/jaxws/JaxwsServiceBuilderTest.java
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/tools/javato/src/test/java/org/apache/cxf/tools/java2wsdl/processor/internal/jaxws/JaxwsServiceBuilderTest.java?view=diff&rev=527424&r1=527423&r2=527424
==============================================================================
--- incubator/cxf/trunk/tools/javato/src/test/java/org/apache/cxf/tools/java2wsdl/processor/internal/jaxws/JaxwsServiceBuilderTest.java
(original)
+++ incubator/cxf/trunk/tools/javato/src/test/java/org/apache/cxf/tools/java2wsdl/processor/internal/jaxws/JaxwsServiceBuilderTest.java
Wed Apr 11 02:07:59 2007
@@ -27,11 +27,13 @@
 import org.apache.cxf.tools.fortest.classnoanno.docbare.Stock;
 import org.apache.cxf.tools.fortest.withannotation.doc.Hello;
 import org.apache.cxf.tools.java2wsdl.generator.wsdl11.WSDL11Generator;
+import org.apache.cxf.tools.util.AnnotationUtil;
+import org.apache.hello_world_rpclit.GreeterRPCLit;
 
 public class JaxwsServiceBuilderTest extends ProcessorTestBase {
     JaxwsServiceBuilder builder = new JaxwsServiceBuilder();
     WSDL11Generator generator = new WSDL11Generator();
-    
+
     public void setUp() throws Exception {
         super.setUp();
         builder.setBus(BusFactory.getDefaultBus());
@@ -49,42 +51,188 @@
 
     public void testBare() {
         builder.setServiceClass(Stock.class);
-        ServiceInfo service =  builder.build();
+        ServiceInfo service = builder.build();
         generator.setServiceModel(service);
         File output = getOutputFile("stock_bare.wsdl");
         assertNotNull(output);
         generator.generate(output);
         assertTrue(output.exists());
-        
+
         String expectedFile = getClass().getResource("expected/expected_stock_bare.wsdl").getFile();
         assertFileEquals(expectedFile, output.getAbsolutePath());
     }
 
     public void xtestWrapped() {
         builder.setServiceClass(org.apache.cxf.tools.fortest.withannotation.doc.Hello.class);
-        ServiceInfo service =  builder.build();
+        ServiceInfo service = builder.build();
         generator.setServiceModel(service);
         File output = getOutputFile("hello_wrapped.wsdl");
         assertNotNull(output);
         generator.generate(output);
-        assertTrue(output.exists());        
+        assertTrue(output.exists());
     }
-    
-    //TODO: CXF-519
+
+    // TODO: CXF-519
     public void xtestAsyn() throws Exception {
         builder.setServiceClass(org.apache.hello_world_async_soap_http.GreeterAsync.class);
-        ServiceInfo service =  builder.build();
+        ServiceInfo service = builder.build();
         generator.setServiceModel(service);
         File output = getOutputFile("hello_async.wsdl");
         assertNotNull(output);
         generator.generate(output);
-        assertTrue(output.exists());   
+        assertTrue(output.exists());
 
         String expectedFile = this.getClass().getResource("expected/expected_hello_world_async.wsdl")
             .getFile();
         assertFileEquals(expectedFile, output.getAbsolutePath());
     }
-    
+
+    public void testRPCLit() throws Exception {
+        builder.setServiceClass(GreeterRPCLit.class);
+        ServiceInfo service = builder.build();
+
+        generator.setServiceModel(service);
+        File file = getOutputFile("rpc_lit.wsdl");
+        assertNotNull(output);
+        generator.generate(file);
+        assertTrue(output.exists());
+
+        //String expectedFile = this.getClass().getResource("resources/expected_rpc_lit.wsdl").getFile();
+        //compareTextFile(expectedFile, output.getAbsolutePath());
+
+    }
+
+    // TODO:
+    public void xtestDocWrapparBare() throws Exception {
+
+        builder.setServiceClass(org.apache.hello_world_doc_wrapped_bare.Greeter.class);
+        ServiceInfo service = builder.build();
+
+        generator.setServiceModel(service);
+        File file = getOutputFile("doc_wrapped_bare.wsdl");
+        assertNotNull(output);
+        generator.generate(file);
+        assertTrue(output.exists());
+
+    }
+
+    // TODO:
+    public void xtestDocLitUseClassPathFlag() throws Exception {
+        builder.setServiceClass(org.apache.hello_world_doc_lit.Greeter.class);
+        ServiceInfo service = builder.build();
+
+        generator.setServiceModel(service);
+        File file = getOutputFile("doc_lit.wsdl");
+        assertNotNull(output);
+        generator.generate(file);
+        assertTrue(output.exists());
+    }
+
+    // TODO:
+    public void xtestSOAP12() throws Exception {
+        builder.setServiceClass(org.apache.hello_world_soap12_http.Greeter.class);
+        ServiceInfo service = builder.build();
+
+        generator.setServiceModel(service);
+        File file = getOutputFile("soap12.wsdl");
+        assertNotNull(output);
+        generator.generate(file);
+        assertTrue(output.exists());
+
+    }
+
+    // TODO:
+    public void xtestRPCWithoutParentBindingAnnotation() throws Exception {
+        builder.setServiceClass(org.apache.cxf.tools.fortest.withannotation.rpc.Hello.class);
+        ServiceInfo service = builder.build();
+
+        generator.setServiceModel(service);
+        File file = getOutputFile("rpc_lit_service_no_anno.wsdl");
+        assertNotNull(output);
+        generator.generate(file);
+        assertTrue(output.exists());
+
+    }
+
+    // TODO:
+    public void xtestDocWrappedWithoutWrapperClass() throws Exception {
+        builder.setServiceClass(org.apache.cxf.tools.fortest.withannotation.doc.HelloWrapped.class);
+        ServiceInfo service = builder.build();
+
+        generator.setServiceModel(service);
+        File file = getOutputFile("doc_lit_wrapped_no_anno.wsdl");
+        assertNotNull(output);
+        generator.generate(file);
+        assertTrue(output.exists());
+
+    }
+
+    // TODO:
+    public void xtestSOAPBindingRPCOnMethod() throws Exception {
+        builder.setServiceClass(org.apache.cxf.tools.fortest.withannotation.rpc.HelloWrongAnnotation.class);
+        ServiceInfo service = builder.build();
+
+        generator.setServiceModel(service);
+        File file = getOutputFile("rpc_on_method.wsdl");
+        assertNotNull(output);
+        generator.generate(file);
+        assertTrue(output.exists());
+
+    }
+
+    // TODO:
+    public void xtestDocWrappedWithLocalName() throws Exception {
+        builder.setServiceClass(org.apache.cxf.tools.fortest.withannotation.doc.Stock.class);
+        ServiceInfo service = builder.build();
+
+        generator.setServiceModel(service);
+        File file = getOutputFile("doc_lit_wrapped_localName.wsdl");
+        assertNotNull(output);
+        generator.generate(file);
+        assertTrue(output.exists());
+
+    }
+
+    // TODO:
+    public void xtestDocWrappedNoWebParam() throws Exception {
+        builder.setServiceClass(org.apache.cxf.tools.fortest.withannotation.doc.HelloWithNoWebParam.class);
+        ServiceInfo service = builder.build();
+
+        generator.setServiceModel(service);
+        File file = getOutputFile("doc_lit_wrapped_webparam.wsdl");
+        assertNotNull(output);
+        generator.generate(file);
+        assertTrue(output.exists());
+    }
+
+    // TODO:
+    public void xtestSoapHeader() throws Exception {
+
+        builder.setServiceClass(org.apache.samples.headers.HeaderTester.class);
+        ServiceInfo service = builder.build();
+
+        generator.setServiceModel(service);
+        File file = getOutputFile("soap_header.wsdl");
+        assertNotNull(output);
+        generator.generate(file);
+        assertTrue(output.exists());
+
+    }
+
+    // TODO:
+    public void xtestCXF188() throws Exception {
+        Class clz = AnnotationUtil.loadClass("org.apache.cxf.tools.fortest.cxf188.Demo",
getClass()
+            .getClassLoader());
+        builder.setServiceClass(clz);
+        ServiceInfo service = builder.build();
+
+        generator.setServiceModel(service);
+        File file = getOutputFile("cxf188.wsdl");
+        assertNotNull(output);
+        generator.generate(file);
+        assertTrue(output.exists());
+    }
+
     private File getOutputFile(String fileName) {
         return new File(output, fileName);
     }



Mime
View raw message