You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cxf.apache.org by dk...@apache.org on 2011/07/27 19:53:56 UTC

svn commit: r1151560 - in /cxf/branches/2.4.x-fixes: ./ rt/javascript/src/test/java/org/apache/cxf/javascript/ rt/javascript/src/test/resources/ rt/javascript/src/test/resources/org/apache/cxf/javascript/ tools/wsdlto/test/src/test/java/org/apache/cxf/...

Author: dkulp
Date: Wed Jul 27 17:53:55 2011
New Revision: 1151560

URL: http://svn.apache.org/viewvc?rev=1151560&view=rev
Log:
Merged revisions 1151558 via svnmerge from 
https://svn.apache.org/repos/asf/cxf/trunk

........
  r1151558 | dkulp | 2011-07-27 13:50:16 -0400 (Wed, 27 Jul 2011) | 1 line
  
  Flip another couple tests to use dynamic ports.
........

Modified:
    cxf/branches/2.4.x-fixes/   (props changed)
    cxf/branches/2.4.x-fixes/rt/javascript/src/test/java/org/apache/cxf/javascript/JsHttpRequestTest.java
    cxf/branches/2.4.x-fixes/rt/javascript/src/test/resources/XMLHttpRequestTestBeans.xml
    cxf/branches/2.4.x-fixes/rt/javascript/src/test/resources/org/apache/cxf/javascript/XMLHttpRequestTests.js
    cxf/branches/2.4.x-fixes/tools/wsdlto/test/src/test/java/org/apache/cxf/tools/wsdlto/jaxws/CodeGenBugTest.java
    cxf/branches/2.4.x-fixes/tools/wsdlto/test/src/test/resources/wsdl2java_wsdl/remote-hello_world_binding.xsd

Propchange: cxf/branches/2.4.x-fixes/
            ('svn:mergeinfo' removed)

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

Modified: cxf/branches/2.4.x-fixes/rt/javascript/src/test/java/org/apache/cxf/javascript/JsHttpRequestTest.java
URL: http://svn.apache.org/viewvc/cxf/branches/2.4.x-fixes/rt/javascript/src/test/java/org/apache/cxf/javascript/JsHttpRequestTest.java?rev=1151560&r1=1151559&r2=1151560&view=diff
==============================================================================
--- cxf/branches/2.4.x-fixes/rt/javascript/src/test/java/org/apache/cxf/javascript/JsHttpRequestTest.java (original)
+++ cxf/branches/2.4.x-fixes/rt/javascript/src/test/java/org/apache/cxf/javascript/JsHttpRequestTest.java Wed Jul 27 17:53:55 2011
@@ -35,6 +35,7 @@ import org.apache.cxf.javascript.Javascr
 import org.apache.cxf.jaxws.EndpointImpl;
 import org.apache.cxf.test.AbstractCXFSpringTest;
 import org.apache.cxf.test.XPathAssert;
+import org.apache.cxf.testutil.common.TestUtil;
 
 import org.junit.Before;
 import org.junit.Ignore;
@@ -68,6 +69,7 @@ public class JsHttpRequestTest extends A
 
     @Override
     protected String[] getConfigLocations() {
+        TestUtil.getPortNumber(JsHttpRequestTest.class);
         return new String[] {"classpath:XMLHttpRequestTestBeans.xml"};
     }
     

Modified: cxf/branches/2.4.x-fixes/rt/javascript/src/test/resources/XMLHttpRequestTestBeans.xml
URL: http://svn.apache.org/viewvc/cxf/branches/2.4.x-fixes/rt/javascript/src/test/resources/XMLHttpRequestTestBeans.xml?rev=1151560&r1=1151559&r2=1151560&view=diff
==============================================================================
--- cxf/branches/2.4.x-fixes/rt/javascript/src/test/resources/XMLHttpRequestTestBeans.xml (original)
+++ cxf/branches/2.4.x-fixes/rt/javascript/src/test/resources/XMLHttpRequestTestBeans.xml Wed Jul 27 17:53:55 2011
@@ -31,10 +31,12 @@
            http://www.springframework.org/schema/beans
               http://www.springframework.org/schema/beans/spring-beans.xsd">
 
+    <bean class="org.springframework.beans.factory.config.PropertyPlaceholderConfigurer"/>
+
 	<import resource="classpath:META-INF/cxf/cxf.xml" />
 
 	<httpj:engine-factory bus="cxf">
-		<httpj:engine port="8808">
+		<httpj:engine port="${testutil.ports.JsHttpRequestTest}">
 			<httpj:handlers>
 				<bean class="org.eclipse.jetty.server.handler.ContextHandler">
 					<property name="contextPath" value="/" />
@@ -64,7 +66,7 @@
 
 	<jaxws:endpoint id="greeter-service-endpoint"
 		implementor="org.apache.hello_world_xml_http.wrapped.GreeterImpl"
-		address="http://localhost:8808/Greeter">
+		address="http://localhost:${testutil.ports.JsHttpRequestTest}/Greeter">
 	</jaxws:endpoint>
 
 </beans>
\ No newline at end of file

Modified: cxf/branches/2.4.x-fixes/rt/javascript/src/test/resources/org/apache/cxf/javascript/XMLHttpRequestTests.js
URL: http://svn.apache.org/viewvc/cxf/branches/2.4.x-fixes/rt/javascript/src/test/resources/org/apache/cxf/javascript/XMLHttpRequestTests.js?rev=1151560&r1=1151559&r2=1151560&view=diff
==============================================================================
--- cxf/branches/2.4.x-fixes/rt/javascript/src/test/resources/org/apache/cxf/javascript/XMLHttpRequestTests.js (original)
+++ cxf/branches/2.4.x-fixes/rt/javascript/src/test/resources/org/apache/cxf/javascript/XMLHttpRequestTests.js Wed Jul 27 17:53:55 2011
@@ -50,7 +50,8 @@ function testSyncHttpFetch() {
 	
 	var r = new XMLHttpRequest();
 	
-	r.open("GET", "http://localhost:8808/test.html", false);
+    var port = java.lang.System.getProperty("testutil.ports.JsHttpRequestTest");
+	r.open("GET", "http://localhost:" + port + "/test.html", false);
 	if (r.readyState != r.OPENED) {
 		assertionFailed("state not OPENED after OPEN");
 	}
@@ -71,8 +72,9 @@ function testStateNotificationSync() {
 	// create closure.
 	r.onreadystatechange = function() {
 		globalState = r.readyState;
-	}	
-	r.open("GET", "http://localhost:8808/test.html", false);
+    }
+    var port = java.lang.System.getProperty("testutil.ports.JsHttpRequestTest");
+	r.open("GET", "http://localhost:" + port + "/test.html", false);
 	if (r.readyState != r.OPENED) {
 		assertionFailed("state not OPENED after OPEN");
 	}
@@ -138,7 +140,8 @@ function testAsyncHttpFetch1() {
 		}
 	}	
 
-	r.open("GET", "http://localhost:8808/test.html", true);
+    var port = java.lang.System.getProperty("testutil.ports.JsHttpRequestTest");
+	r.open("GET", "http://localhost:" + port + "/test.html", true);
 	if (r.readyState != r.OPENED) {
 		assertionFailed("state not OPENED after OPEN");
 	}

Modified: cxf/branches/2.4.x-fixes/tools/wsdlto/test/src/test/java/org/apache/cxf/tools/wsdlto/jaxws/CodeGenBugTest.java
URL: http://svn.apache.org/viewvc/cxf/branches/2.4.x-fixes/tools/wsdlto/test/src/test/java/org/apache/cxf/tools/wsdlto/jaxws/CodeGenBugTest.java?rev=1151560&r1=1151559&r2=1151560&view=diff
==============================================================================
--- cxf/branches/2.4.x-fixes/tools/wsdlto/test/src/test/java/org/apache/cxf/tools/wsdlto/jaxws/CodeGenBugTest.java (original)
+++ cxf/branches/2.4.x-fixes/tools/wsdlto/test/src/test/java/org/apache/cxf/tools/wsdlto/jaxws/CodeGenBugTest.java Wed Jul 27 17:53:55 2011
@@ -24,6 +24,7 @@ import java.io.File;
 import java.io.FileInputStream;
 import java.lang.reflect.Method;
 import java.lang.reflect.Modifier;
+import java.net.ServerSocket;
 import java.util.Arrays;
 import java.util.List;
 
@@ -51,14 +52,11 @@ import org.eclipse.jetty.server.handler.
 import org.junit.Ignore;
 import org.junit.Test;
 
-
-
 public class CodeGenBugTest extends AbstractCodeGenTest {
 
     @Test
     public void testCXF2944() throws Exception {
-        env.put(ToolConstants.CFG_WSDLURL,
-                getLocation("/wsdl2java_wsdl/cxf2944/cxf2944.wsdl"));
+        env.put(ToolConstants.CFG_WSDLURL, getLocation("/wsdl2java_wsdl/cxf2944/cxf2944.wsdl"));
         env.put(ToolConstants.CFG_ALLOW_ELEMENT_REFS, "true");
         processor.setContext(env);
         processor.execute();
@@ -70,8 +68,7 @@ public class CodeGenBugTest extends Abst
 
     @Test
     public void testCXF2935() throws Exception {
-        env.put(ToolConstants.CFG_WSDLURL,
-                getLocation("/wsdl2java_wsdl/cxf2935/webservice.wsdl"));
+        env.put(ToolConstants.CFG_WSDLURL, getLocation("/wsdl2java_wsdl/cxf2935/webservice.wsdl"));
         env.put(ToolConstants.CFG_ALLOW_ELEMENT_REFS, "true");
         processor.setContext(env);
         processor.execute();
@@ -82,8 +79,7 @@ public class CodeGenBugTest extends Abst
 
     @Test
     public void testCXF1969() throws Exception {
-        env.put(ToolConstants.CFG_WSDLURL,
-                getLocation("/wsdl2java_wsdl/cxf1969/report_incident.wsdl"));
+        env.put(ToolConstants.CFG_WSDLURL, getLocation("/wsdl2java_wsdl/cxf1969/report_incident.wsdl"));
         processor.setContext(env);
 
         try {
@@ -132,7 +128,7 @@ public class CodeGenBugTest extends Abst
 
         WebService webServiceAnn = AnnotationUtil.getPrivClassAnnotation(clz, WebService.class);
         assertTrue("Impl class should note generate name property value in webService annotation",
-                    webServiceAnn.name().equals(""));
+                   webServiceAnn.name().equals(""));
         assertFalse("Impl class should generate portName property value in webService annotation",
                     webServiceAnn.portName().equals(""));
         assertFalse("Impl class should generate serviceName property value in webService annotation",
@@ -239,8 +235,8 @@ public class CodeGenBugTest extends Abst
 
         String[] args = new String[] {"-d", output.getCanonicalPath(), "-nexclude",
                                       "http://apache.org/test/types=com.iona", "-nexclude",
-                                      "http://apache.org/Invoice", "-compile",
-                                      "-classdir", output.getCanonicalPath() + "/classes",
+                                      "http://apache.org/Invoice", "-compile", "-classdir",
+                                      output.getCanonicalPath() + "/classes",
                                       getLocation("/wsdl2java_wsdl/hello_world_exclude.wsdl")};
         WSDLToJava.main(args);
 
@@ -261,7 +257,6 @@ public class CodeGenBugTest extends Abst
 
     }
 
-
     @Test
     public void testExcludeNSWithoutPackageName() throws Exception {
 
@@ -290,8 +285,7 @@ public class CodeGenBugTest extends Abst
 
     @Test
     public void testDefaultLoadNSMappingOFF() throws Exception {
-        String[] args = new String[] {"-dns", "false",
-                                      "-d", output.getCanonicalPath(), "-noAddressBinding",
+        String[] args = new String[] {"-dns", "false", "-d", output.getCanonicalPath(), "-noAddressBinding",
                                       getLocation("/wsdl2java_wsdl/basic_callback.wsdl")};
 
         WSDLToJava.main(args);
@@ -426,7 +420,7 @@ public class CodeGenBugTest extends Abst
             bout.write(buffer, 0, size);
             index = bout.toString()
                 .indexOf("new QName(\"http://cxf.apache.org/w2j/hello_world_soap_http/service\","
-                        + " \"SOAPService_Test1\")");
+                             + " \"SOAPService_Test1\")");
             if (index > 0) {
                 break;
             }
@@ -465,7 +459,6 @@ public class CodeGenBugTest extends Abst
         assertTrue(address.exists());
     }
 
-
     @Test
     public void testDefatultNsMapExclude() throws Exception {
         env.put(ToolConstants.CFG_ALL, ToolConstants.CFG_ALL);
@@ -489,15 +482,21 @@ public class CodeGenBugTest extends Abst
     @Test
     @Ignore
     public void testHelloWorldExternalBindingFile() throws Exception {
-        Server server = new Server(8585);
+        ServerSocket sock = new ServerSocket(0);
+        int port = sock.getLocalPort();
+        Server server = new Server(port);
+        sock.close();
 
         ResourceHandler reshandler = new ResourceHandler();
         reshandler.setResourceBase(getLocation("/wsdl2java_wsdl/"));
-        // this is the only handler we're supposed to need, so we don't need to 'add' it.
+        // this is the only handler we're supposed to need, so we don't need to
+        // 'add' it.
         server.setHandler(reshandler);
         server.start();
-        env.put(ToolConstants.CFG_WSDLURL, "http://localhost:8585/hello_world.wsdl");
-        env.put(ToolConstants.CFG_BINDING, "http://localhost:8585/remote-hello_world_binding.xsd");
+        env.put(ToolConstants.CFG_WSDLURL, "http://localhost:" 
+            + port + "/hello_world.wsdl");
+        env.put(ToolConstants.CFG_BINDING, "http://localhost:"
+            + port + "/remote-hello_world_binding.xsd");
         processor.setContext(env);
         processor.execute();
         try {
@@ -509,7 +508,6 @@ public class CodeGenBugTest extends Abst
 
     }
 
-
     @Test
     public void testDefaultNSWithPkg() throws Exception {
         String[] args = new String[] {"-d", output.getCanonicalPath(), "-p", "org.cxf", "-noAddressBinding",
@@ -541,8 +539,7 @@ public class CodeGenBugTest extends Abst
 
     @Test
     public void testCXF677() throws Exception {
-        String[] args = new String[] {"-d", output.getCanonicalPath(),
-                                      "-b",
+        String[] args = new String[] {"-d", output.getCanonicalPath(), "-b",
                                       getLocation("/wsdl2java_wsdl/hello-mime-binding.xml"),
                                       getLocation("/wsdl2java_wsdl/hello-mime.wsdl")};
 
@@ -554,7 +551,7 @@ public class CodeGenBugTest extends Abst
         String str4 = "http://cxf.apache.org/w2j/hello_world_mime/types";
 
         String file = getStringFromFile(new File(output.getCanonicalPath()
-                                        + "/org/apache/cxf/w2j/hello_world_mime/Hello.java"));
+                                                 + "/org/apache/cxf/w2j/hello_world_mime/Hello.java"));
 
         assertTrue(file.contains(str1));
         assertTrue(file.contains(str2));
@@ -570,7 +567,7 @@ public class CodeGenBugTest extends Abst
         processor.execute();
 
         String results = FileUtils.getStringFromFile(new File(output.getCanonicalPath(),
-                                                    "org/apache/sayhi/SayHi.java"));
+                                                              "org/apache/sayhi/SayHi.java"));
         assertTrue(results.trim().length() > 0);
 
         assertTrue(results.indexOf("@WebResult(name  =  \"return\",  "
@@ -578,7 +575,6 @@ public class CodeGenBugTest extends Abst
         assertTrue(results.indexOf("@WebResult(name  =  \"return\",  targetNamespace  =  \"\")") != -1);
     }
 
-
     @Test
     public void testCXF627() throws Exception {
 
@@ -588,10 +584,9 @@ public class CodeGenBugTest extends Abst
         try {
             processor.execute();
         } catch (Exception ex) {
-            //ignore
+            // ignore
         }
 
-
         Class clz = classLoader.loadClass("org.apache.cxf.w2j.hello_world_soap_http.Greeter");
         assertEquals(3, clz.getDeclaredMethods().length);
 
@@ -679,7 +674,6 @@ public class CodeGenBugTest extends Abst
 
     }
 
-
     @Test
     public void testAntFile() throws Exception {
         env.put(ToolConstants.CFG_WSDLURL, getLocation("/wsdl2java_wsdl/hello_world.wsdl"));
@@ -699,8 +693,7 @@ public class CodeGenBugTest extends Abst
     @Test
     public void testNonUniqueBody() throws Exception {
         try {
-            env.put(ToolConstants.CFG_WSDLURL,
-                    getLocation("/wsdl2java_wsdl/cxf939/bug.wsdl"));
+            env.put(ToolConstants.CFG_WSDLURL, getLocation("/wsdl2java_wsdl/cxf939/bug.wsdl"));
             // env.put(ToolConstants.CFG_VALIDATE_WSDL,
             // ToolConstants.CFG_VALIDATE_WSDL);
             processor.setContext(env);
@@ -721,8 +714,7 @@ public class CodeGenBugTest extends Abst
     @Test
     public void testWrapperStyleNameCollision() throws Exception {
         try {
-            env.put(ToolConstants.CFG_WSDLURL,
-                    getLocation("/wsdl2java_wsdl/cxf918/bug.wsdl"));
+            env.put(ToolConstants.CFG_WSDLURL, getLocation("/wsdl2java_wsdl/cxf918/bug.wsdl"));
             processor.setContext(env);
             processor.execute();
         } catch (Exception e) {
@@ -732,16 +724,16 @@ public class CodeGenBugTest extends Abst
             QName stringName = new QName(ns2, "string");
             QName intName = new QName(ns2, "int");
 
-            Message msg = new Message("WRAPPER_STYLE_NAME_COLLISION", UniqueBodyValidator.LOG,
-                                      elementName, stringName, intName);
+            Message msg = new Message("WRAPPER_STYLE_NAME_COLLISION", UniqueBodyValidator.LOG, elementName,
+                                      stringName, intName);
             assertEquals(msg.toString().trim(), e.getMessage().trim());
         }
     }
+
     @Test
     public void testNonWrapperStyleNameCollision() throws Exception {
         try {
-            env.put(ToolConstants.CFG_WSDLURL,
-                    getLocation("/wsdl2java_wsdl/cxf918/bug2.wsdl"));
+            env.put(ToolConstants.CFG_WSDLURL, getLocation("/wsdl2java_wsdl/cxf918/bug2.wsdl"));
             processor.setContext(env);
             processor.execute();
             fail("The cxf918/bug2.wsdl should not have generated code");
@@ -753,8 +745,7 @@ public class CodeGenBugTest extends Abst
     @Test
     public void testParameterOrderNoOutputMessage() throws Exception {
         try {
-            env.put(ToolConstants.CFG_WSDLURL,
-                    getLocation("/wsdl2java_wsdl/bug967.wsdl"));
+            env.put(ToolConstants.CFG_WSDLURL, getLocation("/wsdl2java_wsdl/bug967.wsdl"));
             processor.setContext(env);
             processor.execute();
         } catch (Exception e) {
@@ -765,13 +756,12 @@ public class CodeGenBugTest extends Abst
     @Test
     public void testParameterOrderDifferentNS() throws Exception {
         try {
-            env.put(ToolConstants.CFG_WSDLURL,
-                    getLocation("/wsdl2java_wsdl/bug978/bug.wsdl"));
+            env.put(ToolConstants.CFG_WSDLURL, getLocation("/wsdl2java_wsdl/bug978/bug.wsdl"));
             processor.setContext(env);
             processor.execute();
 
             String results = FileUtils.getStringFromFile(new File(output.getCanonicalPath(),
-                                                        "org/tempuri/GreeterRPCLit.java"));
+                                                                  "org/tempuri/GreeterRPCLit.java"));
             assertTrue(results.indexOf("@WebParam(partName  =  \"inInt\",  name  =  \"inInt\")") != -1);
             assertTrue(results.indexOf("Style.RPC") != -1);
 
@@ -805,8 +795,9 @@ public class CodeGenBugTest extends Abst
         processor.setContext(env);
         processor.execute();
 
-        String results = FileUtils.getStringFromFile(new File(output.getCanonicalPath(),
-                                                    "soapinterface/ems/esendex/com/AccountServiceSoap.java"));
+        String results = FileUtils
+            .getStringFromFile(new File(output.getCanonicalPath(),
+                                        "soapinterface/ems/esendex/com/AccountServiceSoap.java"));
         assertTrue(results.indexOf("public  int  getMessageLimit") != -1);
         assertTrue(results.indexOf("name  =  \"MessengerHeader") != -1);
         assertTrue(results.indexOf("header  =  true") != -1);
@@ -814,26 +805,22 @@ public class CodeGenBugTest extends Abst
 
     @Test
     public void testBindingForImportWSDL() throws Exception {
-        env.put(ToolConstants.CFG_WSDLURL,
-                getLocation("/wsdl2java_wsdl/cxf1095/hello_world_services.wsdl"));
-        env.put(ToolConstants.CFG_BINDING,
-                new String[] {getLocation("/wsdl2java_wsdl/cxf1095/binding.xml")
-                              , getLocation("/wsdl2java_wsdl/cxf1095/binding1.xml")});
+        env.put(ToolConstants.CFG_WSDLURL, getLocation("/wsdl2java_wsdl/cxf1095/hello_world_services.wsdl"));
+        env.put(ToolConstants.CFG_BINDING, 
+                new String[] {getLocation("/wsdl2java_wsdl/cxf1095/binding.xml"),
+                              getLocation("/wsdl2java_wsdl/cxf1095/binding1.xml")});
         processor.setContext(env);
         processor.execute();
-        Class clz = classLoader
-        .loadClass("org.apache.cxf.w2j.hello_world.messages.CustomizedFault");
+        Class clz = classLoader.loadClass("org.apache.cxf.w2j.hello_world.messages.CustomizedFault");
         assertNotNull("Customization Fault Class is not generated", clz);
-        Class serviceClz = classLoader
-        .loadClass("org.apache.cxf.w2j.hello_world.services.CustomizedService");
+        Class serviceClz = classLoader.loadClass("org.apache.cxf.w2j.hello_world.services.CustomizedService");
         assertNotNull("Customization Fault Class is not generated", serviceClz);
 
     }
 
     @Test
     public void testReuseJaxwsBindingFile() throws Exception {
-        env.put(ToolConstants.CFG_WSDLURL,
-                getLocation("/wsdl2java_wsdl/cxf1094/hello_world.wsdl"));
+        env.put(ToolConstants.CFG_WSDLURL, getLocation("/wsdl2java_wsdl/cxf1094/hello_world.wsdl"));
         env.put(ToolConstants.CFG_BINDING, getLocation("/wsdl2java_wsdl/cxf1094/async_binding.xml"));
         processor.setContext(env);
         processor.execute();
@@ -845,8 +832,7 @@ public class CodeGenBugTest extends Abst
 
         assertNotNull("jaxws binding file does not take effect for hello_world.wsdl", method1);
 
-        env.put(ToolConstants.CFG_WSDLURL,
-                getLocation("/wsdl2java_wsdl/cxf1094/echo_date.wsdl"));
+        env.put(ToolConstants.CFG_WSDLURL, getLocation("/wsdl2java_wsdl/cxf1094/echo_date.wsdl"));
         env.put(ToolConstants.CFG_BINDING, getLocation("/wsdl2java_wsdl/cxf1094/async_binding.xml"));
         processor.setContext(env);
         processor.execute();
@@ -862,38 +848,33 @@ public class CodeGenBugTest extends Abst
     // See CXF-2135
     @Test
     public void testReuseJaxbBindingFile1() throws Exception {
-        env.put(ToolConstants.CFG_WSDLURL,
-                getLocation("/wsdl2java_wsdl/cxf1094/hello_world.wsdl"));
+        env.put(ToolConstants.CFG_WSDLURL, getLocation("/wsdl2java_wsdl/cxf1094/hello_world.wsdl"));
         env.put(ToolConstants.CFG_BINDING, getLocation("/wsdl2java_wsdl/cxf1094/jaxbbinding.xml"));
         processor.setContext(env);
         processor.execute();
         Class clz = classLoader
             .loadClass("org.apache.cxf.w2j.hello_world_soap_http.types.CreateProcess$MyProcess");
-        assertNotNull("Failed to generate customized class for hello_world.wsdl" , clz);
+        assertNotNull("Failed to generate customized class for hello_world.wsdl", clz);
 
-        env.put(ToolConstants.CFG_WSDLURL,
-                getLocation("/wsdl2java_wsdl/cxf1094/hello_world_oneway.wsdl"));
+        env.put(ToolConstants.CFG_WSDLURL, getLocation("/wsdl2java_wsdl/cxf1094/hello_world_oneway.wsdl"));
         env.put(ToolConstants.CFG_BINDING, getLocation("/wsdl2java_wsdl/cxf1094/jaxbbinding.xml"));
         processor.setContext(env);
         processor.execute();
         Class customizedClz = classLoader.loadClass("org.apache.oneway.types.CreateProcess$MyProcess");
-        assertNotNull("Failed to generate customized class for hello_world_oneway.wsdl",
-                      customizedClz);
+        assertNotNull("Failed to generate customized class for hello_world_oneway.wsdl", customizedClz);
     }
 
     @Test
     public void testBindingXPath() throws Exception {
-        env.put(ToolConstants.CFG_WSDLURL,
-                getLocation("/wsdl2java_wsdl/hello_world.wsdl"));
+        env.put(ToolConstants.CFG_WSDLURL, getLocation("/wsdl2java_wsdl/hello_world.wsdl"));
         env.put(ToolConstants.CFG_BINDING, getLocation("/wsdl2java_wsdl/cxf1106/binding.xml"));
         processor.setContext(env);
         processor.execute();
-        Class clz = classLoader
-        .loadClass("org.apache.cxf.w2j.hello_world_soap_http.Greeter");
+        Class clz = classLoader.loadClass("org.apache.cxf.w2j.hello_world_soap_http.Greeter");
         assertNotNull("Failed to generate SEI class", clz);
         Method[] methods = clz.getMethods();
-        assertEquals("jaxws binding file parse error, number of generated method is not expected"
-                     , 14, methods.length);
+        assertEquals("jaxws binding file parse error, number of generated method is not expected", 14,
+                     methods.length);
 
         boolean existSayHiAsyn = false;
         for (Method m : methods) {
@@ -904,7 +885,6 @@ public class CodeGenBugTest extends Abst
         assertFalse("sayHiAsyn method should not be generated", existSayHiAsyn);
     }
 
-
     @Test
     public void testJaxbCatalog() throws Exception {
         env.put(ToolConstants.CFG_WSDLURL, getLocation("/wsdl2java_wsdl/cxf1112/myservice.wsdl"));
@@ -916,7 +896,6 @@ public class CodeGenBugTest extends Abst
         assertNotNull("Customization types class should be generated", clz);
     }
 
-
     @Test
     public void testCatalog2() throws Exception {
         env.put(ToolConstants.CFG_WSDLURL, "http://example.org/wsdl");
@@ -947,6 +926,7 @@ public class CodeGenBugTest extends Abst
         assertEquals(13, file.list().length);
 
     }
+
     @Test
     public void testCxf1137() {
         try {
@@ -976,8 +956,6 @@ public class CodeGenBugTest extends Abst
         assertNotNull("Customized method 'myGreetMe' in MyGreeter.class is not found", customizedMethod);
     }
 
-
-
     @Test
     public void testJaxwsBindingJavaDoc() throws Exception {
         env.put(ToolConstants.CFG_WSDLURL, getLocation("/wsdl2java_wsdl/hello_world.wsdl"));
@@ -986,14 +964,14 @@ public class CodeGenBugTest extends Abst
         processor.execute();
 
         List<String> results1 = FileUtils.readLines(new File(output.getCanonicalPath(),
-            "org/mypkg/MyGreeter.java"));
+                                                             "org/mypkg/MyGreeter.java"));
 
         assertTrue(results1.contains(" * this is package javadoc"));
         assertTrue(results1.contains(" * this is class javadoc"));
         assertTrue(results1.contains("     * this is method javadoc"));
 
         List<String> results2 = FileUtils.readLines(new File(output.getCanonicalPath(),
-            "org/mypkg/SOAPServiceTest1.java"));
+                                                             "org/mypkg/SOAPServiceTest1.java"));
 
         boolean match1 = false;
         boolean match2 = false;
@@ -1012,16 +990,14 @@ public class CodeGenBugTest extends Abst
 
     @Test
     public void testWSAActionAnno() throws Exception {
-        env.put(ToolConstants.CFG_WSDLURL,
-                getLocation("/wsdl2java_wsdl/cxf1209/hello_world_fault.wsdl"));
+        env.put(ToolConstants.CFG_WSDLURL, getLocation("/wsdl2java_wsdl/cxf1209/hello_world_fault.wsdl"));
         processor.setContext(env);
         processor.execute();
     }
 
     @Test
     public void testCXF964() throws Exception {
-        env.put(ToolConstants.CFG_WSDLURL,
-                getLocation("/wsdl2java_wsdl/cxf964/hello_world_fault.wsdl"));
+        env.put(ToolConstants.CFG_WSDLURL, getLocation("/wsdl2java_wsdl/cxf964/hello_world_fault.wsdl"));
         processor.setContext(env);
         processor.execute();
         Class<?> clz = classLoader.loadClass("org.apache.intfault.BadRecordLitFault");
@@ -1031,10 +1007,8 @@ public class CodeGenBugTest extends Abst
 
     @Test
     public void testCXF1620() throws Exception {
-        env.put(ToolConstants.CFG_WSDLURL,
-                getLocation("/wsdl2java_wsdl/jaxb_custom_extensors.wsdl"));
-        env.put(ToolConstants.CFG_BINDING,
-                getLocation("/wsdl2java_wsdl/jaxb_custom_extensors.xjb"));
+        env.put(ToolConstants.CFG_WSDLURL, getLocation("/wsdl2java_wsdl/jaxb_custom_extensors.wsdl"));
+        env.put(ToolConstants.CFG_BINDING, getLocation("/wsdl2java_wsdl/jaxb_custom_extensors.xjb"));
 
         processor.setContext(env);
         processor.execute();
@@ -1046,7 +1020,6 @@ public class CodeGenBugTest extends Abst
         assertEquals(1, clz.getDeclaredFields().length);
     }
 
-
     @Test
     public void testCXF1048() throws Exception {
 
@@ -1065,7 +1038,6 @@ public class CodeGenBugTest extends Abst
         assertEquals("PingSoapPort", webServiceAnn.portName());
     }
 
-
     @Test
     public void testCXF1694() throws Exception {
 
@@ -1081,18 +1053,17 @@ public class CodeGenBugTest extends Abst
     @Test
     public void testCXF1662() throws Exception {
         String[] args = new String[] {"-d", output.getCanonicalPath(), "-p", "org.cxf",
-                getLocation("/wsdl2java_wsdl/cxf1662/test.wsdl")};
+                                      getLocation("/wsdl2java_wsdl/cxf1662/test.wsdl")};
 
         try {
             WSDLToJava.main(args);
         } catch (ToolException tex) {
             assertTrue(tex.getMessage().contains(" -p option cannot be used when "
-                + "wsdl contains mutiple schemas"));
+                                                     + "wsdl contains mutiple schemas"));
         }
 
-
         String[] args2 = new String[] {"-d", output.getCanonicalPath(), "-p", "org.cxf",
-                getLocation("/wsdl2java_wsdl/cxf1662/test2.wsdl")};
+                                       getLocation("/wsdl2java_wsdl/cxf1662/test2.wsdl")};
         try {
             WSDLToJava.main(args2);
         } catch (ToolException tex) {
@@ -1107,9 +1078,7 @@ public class CodeGenBugTest extends Abst
 
     @Test
     public void testMultiXjcArgs() throws Exception {
-        String[] args = new String[] {"-d", output.getCanonicalPath(),
-                                      "-xjc-Xlocator",
-                                      "-xjc-Xsync-methods",
+        String[] args = new String[] {"-d", output.getCanonicalPath(), "-xjc-Xlocator", "-xjc-Xsync-methods",
                                       getLocation("/wsdl2java_wsdl/hello_world.wsdl")};
         WSDLToJava.main(args);
         File file = new File(output, "org/apache/cxf/w2j/hello_world_soap_http/types/SayHi.java");
@@ -1122,9 +1091,9 @@ public class CodeGenBugTest extends Abst
 
     @Test
     public void testCXF1939() throws Exception {
-        String[] args = new String[] {"-d", output.getCanonicalPath(),
-            "-impl", "-server", "-client", "-autoNameResolution",
-            getLocation("/wsdl2java_wsdl/cxf1939/hello_world.wsdl")};
+        String[] args = new String[] {"-d", output.getCanonicalPath(), "-impl", "-server", "-client",
+                                      "-autoNameResolution",
+                                      getLocation("/wsdl2java_wsdl/cxf1939/hello_world.wsdl")};
         WSDLToJava.main(args);
 
         assertNotNull(output);
@@ -1132,17 +1101,15 @@ public class CodeGenBugTest extends Abst
         assertTrue(new File(output, "org/apache/cxf/w2j/hello_world_soap_http/GreeterImpl1.java").exists());
         assertTrue(new File(output,
                             "org/apache/cxf/w2j/hello_world_soap_http/TestServiceName.java").exists());
-        assertTrue(new File(output,
-                            "org/apache/cxf/w2j/hello_world_soap_http/TestServiceName1.java").exists());
+        assertTrue(new File(output, "org/apache/cxf/w2j/hello_world_soap_http/TestServiceName1.java")
+            .exists());
     }
 
-    
     @Test
     public void testCXF3105() throws Exception {
-        String[] args = new String[] {"-d", output.getCanonicalPath(),
-            "-impl", "-server", "-client", 
-            "-b", getLocation("/wsdl2java_wsdl/cxf3105/ws-binding.xml"),
-            getLocation("/wsdl2java_wsdl/cxf3105/cxf3105.wsdl")};
+        String[] args = new String[] {"-d", output.getCanonicalPath(), "-impl", "-server", "-client", "-b",
+                                      getLocation("/wsdl2java_wsdl/cxf3105/ws-binding.xml"),
+                                      getLocation("/wsdl2java_wsdl/cxf3105/cxf3105.wsdl")};
         WSDLToJava.main(args);
 
         assertNotNull(output);
@@ -1156,13 +1123,14 @@ public class CodeGenBugTest extends Abst
     @Test
     public void testOverloadWithAction() throws Exception {
         String[] args = new String[] {"-d", output.getCanonicalPath(),
-            getLocation("/wsdl2java_wsdl/hello_world_overload.wsdl")};
+                                      getLocation("/wsdl2java_wsdl/hello_world_overload.wsdl")};
         WSDLToJava.main(args);
-        
+
         assertNotNull(output);
         File f = new File(output, "org/apache/cxf/w2j/hello_world_soap_http/SayHi.java");
         assertTrue(f.exists());
     }
+
     @Test
     public void testCXF3290() throws Exception {
         env.put(ToolConstants.CFG_COMPILE, "compile");
@@ -1171,13 +1139,13 @@ public class CodeGenBugTest extends Abst
         env.put(ToolConstants.CFG_WSDLURL, getLocation("/wsdl2java_wsdl/cxf-3290/bug.wsdl"));
         processor.setContext(env);
         processor.execute();
-        
+
         Class<?> cls = classLoader.loadClass("org.apache.cxf.bugs3290.services.bug1.MyBugService");
         Method m = cls.getMethod("getMyBug1");
         assertEquals(classLoader.loadClass("org.apache.cxf.bugs3290.services.bug2.MyBugService"),
                      m.getReturnType());
     }
-    
+
     @Test
     public void testCXF3353andCXF3491() throws Exception {
         try {

Modified: cxf/branches/2.4.x-fixes/tools/wsdlto/test/src/test/resources/wsdl2java_wsdl/remote-hello_world_binding.xsd
URL: http://svn.apache.org/viewvc/cxf/branches/2.4.x-fixes/tools/wsdlto/test/src/test/resources/wsdl2java_wsdl/remote-hello_world_binding.xsd?rev=1151560&r1=1151559&r2=1151560&view=diff
==============================================================================
--- cxf/branches/2.4.x-fixes/tools/wsdlto/test/src/test/resources/wsdl2java_wsdl/remote-hello_world_binding.xsd (original)
+++ cxf/branches/2.4.x-fixes/tools/wsdlto/test/src/test/resources/wsdl2java_wsdl/remote-hello_world_binding.xsd Wed Jul 27 17:53:55 2011
@@ -19,7 +19,7 @@
 <bindings
     xmlns:xsd="http://www.w3.org/2001/XMLSchema"
     xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"
-    wsdlLocation="http://localhost:8585/hello_world.wsdl"
+    wsdlLocation="hello_world.wsdl"
     xmlns="http://java.sun.com/xml/ns/jaxws">
     <bindings node="wsdl:definitions">
 	<enableAsyncMapping>true</enableAsyncMapping>