From jbossws-commits at lists.jboss.org Fri Mar 26 10:21:37 2010 Content-Type: multipart/mixed; boundary="===============5489380873345641682==" MIME-Version: 1.0 From: jbossws-commits at lists.jboss.org To: jbossws-commits at lists.jboss.org Subject: [jbossws-commits] JBossWS SVN: r11869 - in framework/branches/jbossws-framework-3.1.2/testsuite/test/java/org/jboss/test/ws/jaxws: samples/handlerchain and 1 other directories. Date: Fri, 26 Mar 2010 10:21:36 -0400 Message-ID: <201003261421.o2QELaJ7019380@svn01.web.mwc.hst.phx2.redhat.com> --===============5489380873345641682== Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Author: richard.opalka(a)jboss.com Date: 2010-03-26 10:21:36 -0400 (Fri, 26 Mar 2010) New Revision: 11869 Added: framework/branches/jbossws-framework-3.1.2/testsuite/test/java/org/jboss= /test/ws/jaxws/handlerscope/SOAPEndpointService.java framework/branches/jbossws-framework-3.1.2/testsuite/test/java/org/jboss= /test/ws/jaxws/samples/handlerchain/EndpointWithHandlerChainService.java framework/branches/jbossws-framework-3.1.2/testsuite/test/java/org/jboss= /test/ws/jaxws/samples/logicalhandler/SOAPEndpointJAXBService.java framework/branches/jbossws-framework-3.1.2/testsuite/test/java/org/jboss= /test/ws/jaxws/samples/logicalhandler/SOAPEndpointSourceService.java Modified: framework/branches/jbossws-framework-3.1.2/testsuite/test/java/org/jboss= /test/ws/jaxws/handlerscope/HandlerScopeTestCase.java framework/branches/jbossws-framework-3.1.2/testsuite/test/java/org/jboss= /test/ws/jaxws/handlerscope/SOAPEndpoint.java framework/branches/jbossws-framework-3.1.2/testsuite/test/java/org/jboss= /test/ws/jaxws/samples/handlerchain/EndpointWithHandlerChain.java framework/branches/jbossws-framework-3.1.2/testsuite/test/java/org/jboss= /test/ws/jaxws/samples/handlerchain/HandlerChainTestCase.java framework/branches/jbossws-framework-3.1.2/testsuite/test/java/org/jboss= /test/ws/jaxws/samples/logicalhandler/LogicalHandlerJAXBTestCase.java framework/branches/jbossws-framework-3.1.2/testsuite/test/java/org/jboss= /test/ws/jaxws/samples/logicalhandler/LogicalHandlerSourceTestCase.java framework/branches/jbossws-framework-3.1.2/testsuite/test/java/org/jboss= /test/ws/jaxws/samples/logicalhandler/SOAPEndpointJAXB.java framework/branches/jbossws-framework-3.1.2/testsuite/test/java/org/jboss= /test/ws/jaxws/samples/logicalhandler/SOAPEndpointSourceDoc.java framework/branches/jbossws-framework-3.1.2/testsuite/test/java/org/jboss= /test/ws/jaxws/samples/logicalhandler/SOAPEndpointSourceRpc.java Log: [JBPAPP-3995] fixing tests - moving @HandlerChain annotation from client SE= I to Service Modified: framework/branches/jbossws-framework-3.1.2/testsuite/test/java/or= g/jboss/test/ws/jaxws/handlerscope/HandlerScopeTestCase.java =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D --- framework/branches/jbossws-framework-3.1.2/testsuite/test/java/org/jbos= s/test/ws/jaxws/handlerscope/HandlerScopeTestCase.java 2010-03-26 14:16:07 = UTC (rev 11868) +++ framework/branches/jbossws-framework-3.1.2/testsuite/test/java/org/jbos= s/test/ws/jaxws/handlerscope/HandlerScopeTestCase.java 2010-03-26 14:21:36 = UTC (rev 11869) @@ -35,6 +35,7 @@ * Test SOAP12 binding type * * @author Thomas.Diesler(a)jboss.org + * @author Richard Opalka * @since 12-Aug-2006 */ public class HandlerScopeTestCase extends JBossWSTest @@ -48,60 +49,23 @@ { URL wsdlURL =3D new URL("http://" + getServerHost() + ":8080/jaxws-h= andlerscope?wsdl"); QName serviceName =3D new QName("http://org.jboss.ws/jaxws/handlersc= ope", "SOAPEndpointService"); - Service service =3D Service.create(wsdlURL, serviceName); + Service service =3D new SOAPEndpointService(wsdlURL, serviceName); SOAPEndpoint port =3D (SOAPEndpoint)service.getPort(SOAPEndpoint.cla= ss); = String retStr =3D port.echo("hello"); - = - if (isIntegrationMetro()) - { - System.out.println("FIXME: [JBWS-1672] Metro does not respect @Ha= ndlerChain on client SEI"); - testForStacksNotSupportingAnnotationOnClienSEI(retStr); - } - else if (isIntegrationCXF()) - { - System.out.println("FIXME: [CXF-1253] CXF does not respect @Handl= erChain on client SEI"); - testForStacksNotSupportingAnnotationOnClienSEI(retStr); - } - else - { - StringBuffer expStr =3D new StringBuffer("hello"); - expStr.append(":SOAP12ClientHandler"); - expStr.append(":SOAPClientHandler"); - expStr.append(":ServiceClientHandler"); - expStr.append(":ServiceWildcardClientHandler"); - expStr.append(":PortClientHandler"); - expStr.append(":PortWildcardClientHandler"); - expStr.append(":GeneralClientHandler"); - expStr.append(":GeneralServerHandler"); - expStr.append(":PortWildcardServerHandler"); - expStr.append(":PortServerHandler"); - expStr.append(":ServiceWildcardServerHandler"); - expStr.append(":ServiceServerHandler"); - expStr.append(":SOAPServerHandler"); - expStr.append(":SOAP12ServerHandler"); - expStr.append(":endpoint"); - expStr.append(":SOAP12ServerHandler"); - expStr.append(":SOAPServerHandler"); - expStr.append(":ServiceServerHandler"); - expStr.append(":ServiceWildcardServerHandler"); - expStr.append(":PortServerHandler"); - expStr.append(":PortWildcardServerHandler"); - expStr.append(":GeneralServerHandler"); - expStr.append(":GeneralClientHandler"); - expStr.append(":PortWildcardClientHandler"); - expStr.append(":PortClientHandler"); - expStr.append(":ServiceWildcardClientHandler"); - expStr.append(":ServiceClientHandler"); - expStr.append(":SOAPClientHandler"); - expStr.append(":SOAP12ClientHandler"); - assertEquals(expStr.toString(), retStr); - } + assertResponse(retStr); } = - private static void testForStacksNotSupportingAnnotationOnClienSEI(Stri= ng retStr) + private static void assertResponse(String retStr) { StringBuffer expStr =3D new StringBuffer("hello"); + expStr.append(":SOAP12ClientHandler"); + expStr.append(":SOAPClientHandler"); + expStr.append(":ServiceClientHandler"); + expStr.append(":ServiceWildcardClientHandler"); + expStr.append(":PortClientHandler"); + expStr.append(":PortWildcardClientHandler"); + expStr.append(":GeneralClientHandler"); expStr.append(":GeneralServerHandler"); expStr.append(":PortWildcardServerHandler"); expStr.append(":PortServerHandler"); @@ -117,6 +81,13 @@ expStr.append(":PortServerHandler"); expStr.append(":PortWildcardServerHandler"); expStr.append(":GeneralServerHandler"); + expStr.append(":GeneralClientHandler"); + expStr.append(":PortWildcardClientHandler"); + expStr.append(":PortClientHandler"); + expStr.append(":ServiceWildcardClientHandler"); + expStr.append(":ServiceClientHandler"); + expStr.append(":SOAPClientHandler"); + expStr.append(":SOAP12ClientHandler"); assertEquals(expStr.toString(), retStr); } } Modified: framework/branches/jbossws-framework-3.1.2/testsuite/test/java/or= g/jboss/test/ws/jaxws/handlerscope/SOAPEndpoint.java =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D --- framework/branches/jbossws-framework-3.1.2/testsuite/test/java/org/jbos= s/test/ws/jaxws/handlerscope/SOAPEndpoint.java 2010-03-26 14:16:07 UTC (rev= 11868) +++ framework/branches/jbossws-framework-3.1.2/testsuite/test/java/org/jbos= s/test/ws/jaxws/handlerscope/SOAPEndpoint.java 2010-03-26 14:21:36 UTC (rev= 11869) @@ -21,7 +21,6 @@ */ package org.jboss.test.ws.jaxws.handlerscope; = -import javax.jws.HandlerChain; import javax.jws.WebMethod; import javax.jws.WebService; import javax.xml.ws.BindingType; @@ -29,7 +28,6 @@ = @WebService(targetNamespace =3D "http://org.jboss.ws/jaxws/handlerscope") @BindingType(value =3D SOAPBinding.SOAP12HTTP_BINDING) -(a)HandlerChain(file =3D "jaxws-client-handlers.xml") public interface SOAPEndpoint { @WebMethod Copied: framework/branches/jbossws-framework-3.1.2/testsuite/test/java/org/= jboss/test/ws/jaxws/handlerscope/SOAPEndpointService.java (from rev 11866, = framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/handlerscope/SO= APEndpointService.java) =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D --- framework/branches/jbossws-framework-3.1.2/testsuite/test/java/org/jbos= s/test/ws/jaxws/handlerscope/SOAPEndpointService.java = (rev 0) +++ framework/branches/jbossws-framework-3.1.2/testsuite/test/java/org/jbos= s/test/ws/jaxws/handlerscope/SOAPEndpointService.java 2010-03-26 14:21:36 U= TC (rev 11869) @@ -0,0 +1,40 @@ +/* + * JBoss, Home of Professional Open Source. + * Copyright 2006, Red Hat Middleware LLC, and individual contributors + * as indicated by the @author tags. See the copyright.txt file in the + * distribution for a full listing of individual contributors. + * + * This is free software; you can redistribute it and/or modify it + * under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation; either version 2.1 of + * the License, or (at your option) any later version. + * + * This software is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this software; if not, write to the Free + * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA + * 02110-1301 USA, or see the FSF site: http://www.fsf.org. + */ +package org.jboss.test.ws.jaxws.handlerscope; + +import java.net.URL; + +import javax.jws.HandlerChain; +import javax.xml.namespace.QName; +import javax.xml.ws.Service; + +/** + * @author Richard Opalka + */ +(a)HandlerChain(file =3D "jaxws-client-handlers.xml") +public class SOAPEndpointService extends Service +{ + public SOAPEndpointService(URL wsdlLocation, QName serviceName) + { + super(wsdlLocation, serviceName); + } +} Modified: framework/branches/jbossws-framework-3.1.2/testsuite/test/java/or= g/jboss/test/ws/jaxws/samples/handlerchain/EndpointWithHandlerChain.java =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D --- framework/branches/jbossws-framework-3.1.2/testsuite/test/java/org/jbos= s/test/ws/jaxws/samples/handlerchain/EndpointWithHandlerChain.java 2010-03-= 26 14:16:07 UTC (rev 11868) +++ framework/branches/jbossws-framework-3.1.2/testsuite/test/java/org/jbos= s/test/ws/jaxws/samples/handlerchain/EndpointWithHandlerChain.java 2010-03-= 26 14:21:36 UTC (rev 11869) @@ -21,13 +21,11 @@ */ package org.jboss.test.ws.jaxws.samples.handlerchain; = -import javax.jws.HandlerChain; import javax.jws.WebService; import javax.jws.soap.SOAPBinding; = @WebService(name=3D"Endpoint") @SOAPBinding(style =3D SOAPBinding.Style.RPC) -(a)HandlerChain(file =3D "jaxws-handlers-client.xml") // relative path fro= m the class file public interface EndpointWithHandlerChain { public String echo(String input); Copied: framework/branches/jbossws-framework-3.1.2/testsuite/test/java/org/= jboss/test/ws/jaxws/samples/handlerchain/EndpointWithHandlerChainService.ja= va (from rev 11866, framework/trunk/testsuite/test/java/org/jboss/test/ws/j= axws/samples/handlerchain/EndpointWithHandlerChainService.java) =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D --- framework/branches/jbossws-framework-3.1.2/testsuite/test/java/org/jbos= s/test/ws/jaxws/samples/handlerchain/EndpointWithHandlerChainService.java = (rev 0) +++ framework/branches/jbossws-framework-3.1.2/testsuite/test/java/org/jbos= s/test/ws/jaxws/samples/handlerchain/EndpointWithHandlerChainService.java 2= 010-03-26 14:21:36 UTC (rev 11869) @@ -0,0 +1,40 @@ +/* + * JBoss, Home of Professional Open Source. + * Copyright 2006, Red Hat Middleware LLC, and individual contributors + * as indicated by the @author tags. See the copyright.txt file in the + * distribution for a full listing of individual contributors. + * + * This is free software; you can redistribute it and/or modify it + * under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation; either version 2.1 of + * the License, or (at your option) any later version. + * + * This software is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this software; if not, write to the Free + * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA + * 02110-1301 USA, or see the FSF site: http://www.fsf.org. + */ +package org.jboss.test.ws.jaxws.samples.handlerchain; + +import java.net.URL; + +import javax.jws.HandlerChain; +import javax.xml.namespace.QName; +import javax.xml.ws.Service; + +/** + * @author Richard Opalka + */ +(a)HandlerChain(file =3D "jaxws-handlers-client.xml") +public class EndpointWithHandlerChainService extends Service +{ + public EndpointWithHandlerChainService(URL wsdlLocation, QName serviceN= ame) + { + super(wsdlLocation, serviceName); + } +} Modified: framework/branches/jbossws-framework-3.1.2/testsuite/test/java/or= g/jboss/test/ws/jaxws/samples/handlerchain/HandlerChainTestCase.java =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D --- framework/branches/jbossws-framework-3.1.2/testsuite/test/java/org/jbos= s/test/ws/jaxws/samples/handlerchain/HandlerChainTestCase.java 2010-03-26 1= 4:16:07 UTC (rev 11868) +++ framework/branches/jbossws-framework-3.1.2/testsuite/test/java/org/jbos= s/test/ws/jaxws/samples/handlerchain/HandlerChainTestCase.java 2010-03-26 1= 4:21:36 UTC (rev 11869) @@ -38,6 +38,7 @@ /** * Test the JSR-181 annotation: javax.jws.HandlerChain * + * @author Richard Opalka * @author Thomas.Diesler(a)jboss.org * @since 15-Oct-2005 */ @@ -50,6 +51,7 @@ return new JBossWSTestSetup(HandlerChainTestCase.class, "jaxws-sampl= es-handlerchain.war"); } = + @SuppressWarnings("unchecked") public void testDynamicHandlerChain() throws Exception { QName serviceName =3D new QName(targetNS, "EndpointImplService"); @@ -57,7 +59,7 @@ = Service service =3D Service.create(wsdlURL, serviceName); Endpoint port =3D (Endpoint)service.getPort(Endpoint.class); - = + BindingProvider bindingProvider =3D (BindingProvider)port; List handlerChain =3D new ArrayList(); handlerChain.add(new LogHandler()); @@ -65,48 +67,29 @@ handlerChain.add(new RoutingHandler()); handlerChain.add(new ClientMimeHandler()); bindingProvider.getBinding().setHandlerChain(handlerChain); - = + String resStr =3D port.echo("Kermit"); assertEquals("Kermit|LogOut|AuthOut|RoutOut|RoutIn|AuthIn|LogIn|endp= oint|LogOut|AuthOut|RoutOut|RoutIn|AuthIn|LogIn", resStr); - = - if (isIntegrationMetro()) - { - System.out.println("FIXME: [JBWS-1671] Metro client handler canno= t set mime header"); - return; - } - if (isIntegrationCXF()) - { - System.out.println("FIXME: [CXF-1507] CXF client handler cannot s= et mime header"); - return; - } - - assertEquals("server-cookie=3Dtrue", ClientMimeHandler.inboundCookie= ); + assertCookies(); } = - public void testHandlerChainOnServiceEndpointInterface() throws Excepti= on + public void testHandlerChainOnService() throws Exception { QName serviceName =3D new QName(targetNS, "EndpointImplService"); URL wsdlURL =3D new URL("http://" + getServerHost() + ":8080/jaxws-s= amples-handlerchain/TestService?wsdl"); = - Service service =3D Service.create(wsdlURL, serviceName); + Service service =3D new EndpointWithHandlerChainService(wsdlURL, ser= viceName); EndpointWithHandlerChain port =3D (EndpointWithHandlerChain)service.= getPort(EndpointWithHandlerChain.class); - = + + String resStr =3D port.echo("Kermit"); + assertEquals("Kermit|LogOut|AuthOut|RoutOut|RoutIn|AuthIn|LogIn|endp= oint|LogOut|AuthOut|RoutOut|RoutIn|AuthIn|LogIn", resStr); + assertCookies(); + } + + private void assertCookies() throws Exception + { if (isIntegrationMetro()) { - System.out.println("FIXME: [JBWS-1672] Metro does not respect @Ha= ndlerChain on client SEI"); - } - else if (isIntegrationCXF()) - { - System.out.println("FIXME: [CXF-1253] CXF does not respect @Handl= erChain on client SEI"); - } - else - { - String resStr =3D port.echo("Kermit"); - assertEquals("Kermit|LogOut|AuthOut|RoutOut|RoutIn|AuthIn|LogIn|e= ndpoint|LogOut|AuthOut|RoutOut|RoutIn|AuthIn|LogIn", resStr); - } - = - if (isIntegrationMetro()) - { System.out.println("FIXME: [JBWS-1671] Metro client handler canno= t set mime header"); return; } Modified: framework/branches/jbossws-framework-3.1.2/testsuite/test/java/or= g/jboss/test/ws/jaxws/samples/logicalhandler/LogicalHandlerJAXBTestCase.java =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D --- framework/branches/jbossws-framework-3.1.2/testsuite/test/java/org/jbos= s/test/ws/jaxws/samples/logicalhandler/LogicalHandlerJAXBTestCase.java 2010= -03-26 14:16:07 UTC (rev 11868) +++ framework/branches/jbossws-framework-3.1.2/testsuite/test/java/org/jbos= s/test/ws/jaxws/samples/logicalhandler/LogicalHandlerJAXBTestCase.java 2010= -03-26 14:21:36 UTC (rev 11869) @@ -35,6 +35,7 @@ /** * Test JAXWS logical handlers * + * @author Richard Opalka * @author Thomas.Diesler(a)jboss.org * @since 12-Aug-2006 */ @@ -49,7 +50,7 @@ { String endpointAddress =3D "http://" + getServerHost() + ":8080/jaxw= s-samples-logicalhandler-jaxb"; QName serviceName =3D new QName("http://org.jboss.ws/jaxws/samples/l= ogicalhandler", "SOAPEndpointService"); - Service service =3D Service.create(new URL(endpointAddress + "?wsdl"= ), serviceName); + Service service =3D new SOAPEndpointJAXBService(new URL(endpointAddr= ess + "?wsdl"), serviceName); SOAPEndpointJAXB port =3D (SOAPEndpointJAXB)service.getPort(SOAPEndp= ointJAXB.class); = BindingProvider bindingProvider =3D (BindingProvider)port; @@ -58,23 +59,9 @@ String retStr =3D port.echo("hello"); = StringBuffer expStr =3D new StringBuffer("hello"); - if (isIntegrationNative()) - { - expStr.append(":Outbound:LogicalJAXBHandler"); - expStr.append(":Outbound:ProtocolHandler"); - expStr.append(":Outbound:PortHandler"); - } - else - { - if (isIntegrationMetro()) - { - System.out.println("FIXME: [JBWS-1672] Metro does not respect = @HandlerChain on client SEI"); - } - else - { - System.out.println("FIXME: [CXF-1253] CXF does not respect @Ha= ndlerChain on client SEI"); - } - } + expStr.append(":Outbound:LogicalJAXBHandler"); + expStr.append(":Outbound:ProtocolHandler"); + expStr.append(":Outbound:PortHandler"); expStr.append(":Inbound:PortHandler"); expStr.append(":Inbound:ProtocolHandler"); expStr.append(":Inbound:LogicalJAXBHandler"); @@ -82,23 +69,9 @@ expStr.append(":Outbound:LogicalJAXBHandler"); expStr.append(":Outbound:ProtocolHandler"); expStr.append(":Outbound:PortHandler"); - if (isIntegrationNative()) - { - expStr.append(":Inbound:PortHandler"); - expStr.append(":Inbound:ProtocolHandler"); - expStr.append(":Inbound:LogicalJAXBHandler"); - } - else - { - if (isIntegrationMetro()) - { - System.out.println("FIXME: [JBWS-1672] Metro does not respect = @HandlerChain on client SEI"); - } - else - { - System.out.println("FIXME: [CXF-1253] CXF does not respect @Ha= ndlerChain on client SEI"); - } - } + expStr.append(":Inbound:PortHandler"); + expStr.append(":Inbound:ProtocolHandler"); + expStr.append(":Inbound:LogicalJAXBHandler"); assertEquals(expStr.toString(), retStr); } } Modified: framework/branches/jbossws-framework-3.1.2/testsuite/test/java/or= g/jboss/test/ws/jaxws/samples/logicalhandler/LogicalHandlerSourceTestCase.j= ava =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D --- framework/branches/jbossws-framework-3.1.2/testsuite/test/java/org/jbos= s/test/ws/jaxws/samples/logicalhandler/LogicalHandlerSourceTestCase.java 20= 10-03-26 14:16:07 UTC (rev 11868) +++ framework/branches/jbossws-framework-3.1.2/testsuite/test/java/org/jbos= s/test/ws/jaxws/samples/logicalhandler/LogicalHandlerSourceTestCase.java 20= 10-03-26 14:21:36 UTC (rev 11869) @@ -46,86 +46,32 @@ = public void testSourceDoc() throws Exception { - String endpointAddress =3D "http://" + getServerHost() + ":8080/jaxw= s-samples-logicalhandler-source/doc"; + URL endpointAddress =3D new URL("http://" + getServerHost() + ":8080= /jaxws-samples-logicalhandler-source/doc?wsdl"); QName serviceName =3D new QName("http://org.jboss.ws/jaxws/samples/l= ogicalhandler", "SOAPEndpointDocService"); - Service service =3D Service.create(new URL(endpointAddress + "?wsdl"= ), serviceName); + Service service =3D new SOAPEndpointSourceService(endpointAddress, s= erviceName); SOAPEndpointSourceDoc port =3D (SOAPEndpointSourceDoc)service.getPor= t(SOAPEndpointSourceDoc.class); = String retStr =3D port.echo("hello"); - = - StringBuffer expStr =3D new StringBuffer("hello"); - if (isIntegrationNative()) - { - expStr.append(":Outbound:LogicalSourceHandler"); - expStr.append(":Outbound:ProtocolHandler"); - expStr.append(":Outbound:PortHandler"); - } - else - { - if (isIntegrationMetro()) - { - System.out.println("FIXME: [JBWS-1672] Metro does not respect = @HandlerChain on client SEI"); - } - else - { - System.out.println("FIXME: [CXF-1253] CXF does not respect @Ha= ndlerChain on client SEI"); - } - } - expStr.append(":Inbound:PortHandler"); - expStr.append(":Inbound:ProtocolHandler"); - expStr.append(":Inbound:LogicalSourceHandler"); - expStr.append(":endpoint"); - expStr.append(":Outbound:LogicalSourceHandler"); - expStr.append(":Outbound:ProtocolHandler"); - expStr.append(":Outbound:PortHandler"); - if (isIntegrationNative()) - { - expStr.append(":Inbound:PortHandler"); - expStr.append(":Inbound:ProtocolHandler"); - expStr.append(":Inbound:LogicalSourceHandler"); - } - else - { - if (isIntegrationMetro()) - { - System.out.println("FIXME: [JBWS-1672] Metro does not respect = @HandlerChain on client SEI"); - } - else - { - System.out.println("FIXME: [CXF-1253] CXF does not respect @Ha= ndlerChain on client SEI"); - } - } - assertEquals(expStr.toString(), retStr); + assertResponse(retStr); } = - public void testSourceRpc() throws Exception { - String endpointAddress =3D "http://" + getServerHost() + ":8080/jaxw= s-samples-logicalhandler-source/rpc"; + URL endpointAddress =3D new URL("http://" + getServerHost() + ":8080= /jaxws-samples-logicalhandler-source/rpc?wsdl"); QName serviceName =3D new QName("http://org.jboss.ws/jaxws/samples/l= ogicalhandler", "SOAPEndpointRpcService"); - Service service =3D Service.create(new URL(endpointAddress + "?wsdl"= ), serviceName); + Service service =3D new SOAPEndpointSourceService(endpointAddress, s= erviceName); SOAPEndpointSourceRpc port =3D (SOAPEndpointSourceRpc)service.getPor= t(SOAPEndpointSourceRpc.class); = String retStr =3D port.echo("hello"); - = + assertResponse(retStr); + } + = + private void assertResponse(String retStr) + { StringBuffer expStr =3D new StringBuffer("hello"); - if (isIntegrationNative()) - { - expStr.append(":Outbound:LogicalSourceHandler"); - expStr.append(":Outbound:ProtocolHandler"); - expStr.append(":Outbound:PortHandler"); - } - else - { - if (isIntegrationMetro()) - { - System.out.println("FIXME: [JBWS-1672] Metro does not respect = @HandlerChain on client SEI"); - } - else - { - System.out.println("FIXME: [CXF-1253] CXF does not respect @Ha= ndlerChain on client SEI"); - } - } + expStr.append(":Outbound:LogicalSourceHandler"); + expStr.append(":Outbound:ProtocolHandler"); + expStr.append(":Outbound:PortHandler"); expStr.append(":Inbound:PortHandler"); expStr.append(":Inbound:ProtocolHandler"); expStr.append(":Inbound:LogicalSourceHandler"); @@ -133,23 +79,9 @@ expStr.append(":Outbound:LogicalSourceHandler"); expStr.append(":Outbound:ProtocolHandler"); expStr.append(":Outbound:PortHandler"); - if (isIntegrationNative()) = - { - expStr.append(":Inbound:PortHandler"); - expStr.append(":Inbound:ProtocolHandler"); - expStr.append(":Inbound:LogicalSourceHandler"); - } - else - { - if (isIntegrationMetro()) - { - System.out.println("FIXME: [JBWS-1672] Metro does not respect = @HandlerChain on client SEI"); - } - else - { - System.out.println("FIXME: [CXF-1253] CXF does not respect @Ha= ndlerChain on client SEI"); - } - } + expStr.append(":Inbound:PortHandler"); + expStr.append(":Inbound:ProtocolHandler"); + expStr.append(":Inbound:LogicalSourceHandler"); assertEquals(expStr.toString(), retStr); } } Modified: framework/branches/jbossws-framework-3.1.2/testsuite/test/java/or= g/jboss/test/ws/jaxws/samples/logicalhandler/SOAPEndpointJAXB.java =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D --- framework/branches/jbossws-framework-3.1.2/testsuite/test/java/org/jbos= s/test/ws/jaxws/samples/logicalhandler/SOAPEndpointJAXB.java 2010-03-26 14:= 16:07 UTC (rev 11868) +++ framework/branches/jbossws-framework-3.1.2/testsuite/test/java/org/jbos= s/test/ws/jaxws/samples/logicalhandler/SOAPEndpointJAXB.java 2010-03-26 14:= 21:36 UTC (rev 11869) @@ -21,7 +21,6 @@ */ package org.jboss.test.ws.jaxws.samples.logicalhandler; = -import javax.jws.HandlerChain; import javax.jws.WebMethod; import javax.jws.WebParam; import javax.jws.WebResult; @@ -30,14 +29,11 @@ import javax.xml.ws.ResponseWrapper; = @WebService(name =3D "SOAPEndpoint", targetNamespace =3D "http://org.jboss= .ws/jaxws/samples/logicalhandler") -(a)HandlerChain(file =3D "jaxws-client-jaxb-handlers.xml") public interface SOAPEndpointJAXB { - @WebMethod @WebResult(targetNamespace =3D "http://org.jboss.ws/jaxws/samples/logic= alhandler", name =3D "result") @RequestWrapper(className =3D "org.jboss.test.ws.jaxws.samples.logicalh= andler.Echo") @ResponseWrapper(className =3D "org.jboss.test.ws.jaxws.samples.logical= handler.EchoResponse") public String echo(@WebParam(targetNamespace =3D "http://org.jboss.ws/j= axws/samples/logicalhandler", name=3D"String_1") String string1); - } Copied: framework/branches/jbossws-framework-3.1.2/testsuite/test/java/org/= jboss/test/ws/jaxws/samples/logicalhandler/SOAPEndpointJAXBService.java (fr= om rev 11866, framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/s= amples/logicalhandler/SOAPEndpointJAXBService.java) =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D --- framework/branches/jbossws-framework-3.1.2/testsuite/test/java/org/jbos= s/test/ws/jaxws/samples/logicalhandler/SOAPEndpointJAXBService.java = (rev 0) +++ framework/branches/jbossws-framework-3.1.2/testsuite/test/java/org/jbos= s/test/ws/jaxws/samples/logicalhandler/SOAPEndpointJAXBService.java 2010-03= -26 14:21:36 UTC (rev 11869) @@ -0,0 +1,40 @@ +/* + * JBoss, Home of Professional Open Source. + * Copyright 2006, Red Hat Middleware LLC, and individual contributors + * as indicated by the @author tags. See the copyright.txt file in the + * distribution for a full listing of individual contributors. + * + * This is free software; you can redistribute it and/or modify it + * under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation; either version 2.1 of + * the License, or (at your option) any later version. + * + * This software is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this software; if not, write to the Free + * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA + * 02110-1301 USA, or see the FSF site: http://www.fsf.org. + */ +package org.jboss.test.ws.jaxws.samples.logicalhandler; + +import java.net.URL; + +import javax.jws.HandlerChain; +import javax.xml.namespace.QName; +import javax.xml.ws.Service; + +/** + * @author Richard Opalka + */ +(a)HandlerChain(file =3D "jaxws-client-jaxb-handlers.xml") +public class SOAPEndpointJAXBService extends Service +{ + public SOAPEndpointJAXBService(URL wsdlLocation, QName serviceName) + { + super(wsdlLocation, serviceName); + } +} Modified: framework/branches/jbossws-framework-3.1.2/testsuite/test/java/or= g/jboss/test/ws/jaxws/samples/logicalhandler/SOAPEndpointSourceDoc.java =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D --- framework/branches/jbossws-framework-3.1.2/testsuite/test/java/org/jbos= s/test/ws/jaxws/samples/logicalhandler/SOAPEndpointSourceDoc.java 2010-03-2= 6 14:16:07 UTC (rev 11868) +++ framework/branches/jbossws-framework-3.1.2/testsuite/test/java/org/jbos= s/test/ws/jaxws/samples/logicalhandler/SOAPEndpointSourceDoc.java 2010-03-2= 6 14:21:36 UTC (rev 11869) @@ -21,7 +21,6 @@ */ package org.jboss.test.ws.jaxws.samples.logicalhandler; = -import javax.jws.HandlerChain; import javax.jws.WebMethod; import javax.jws.WebParam; import javax.jws.WebResult; @@ -30,7 +29,6 @@ import javax.xml.ws.ResponseWrapper; = @WebService(name =3D "SOAPEndpointDoc", targetNamespace =3D "http://org.jb= oss.ws/jaxws/samples/logicalhandler") -(a)HandlerChain(file =3D "jaxws-client-source-handlers.xml") public interface SOAPEndpointSourceDoc { = Modified: framework/branches/jbossws-framework-3.1.2/testsuite/test/java/or= g/jboss/test/ws/jaxws/samples/logicalhandler/SOAPEndpointSourceRpc.java =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D --- framework/branches/jbossws-framework-3.1.2/testsuite/test/java/org/jbos= s/test/ws/jaxws/samples/logicalhandler/SOAPEndpointSourceRpc.java 2010-03-2= 6 14:16:07 UTC (rev 11868) +++ framework/branches/jbossws-framework-3.1.2/testsuite/test/java/org/jbos= s/test/ws/jaxws/samples/logicalhandler/SOAPEndpointSourceRpc.java 2010-03-2= 6 14:21:36 UTC (rev 11869) @@ -21,14 +21,12 @@ */ package org.jboss.test.ws.jaxws.samples.logicalhandler; = -import javax.jws.HandlerChain; import javax.jws.WebMethod; import javax.jws.WebService; import javax.jws.soap.SOAPBinding; import javax.jws.soap.SOAPBinding.Style; = @WebService(name =3D "SOAPEndpointRpc", targetNamespace =3D "http://org.jb= oss.ws/jaxws/samples/logicalhandler") -(a)HandlerChain(file =3D "jaxws-client-source-handlers.xml") @SOAPBinding(style =3D Style.RPC) public interface SOAPEndpointSourceRpc { Copied: framework/branches/jbossws-framework-3.1.2/testsuite/test/java/org/= jboss/test/ws/jaxws/samples/logicalhandler/SOAPEndpointSourceService.java (= from rev 11866, framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws= /samples/logicalhandler/SOAPEndpointSourceService.java) =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D --- framework/branches/jbossws-framework-3.1.2/testsuite/test/java/org/jbos= s/test/ws/jaxws/samples/logicalhandler/SOAPEndpointSourceService.java = (rev 0) +++ framework/branches/jbossws-framework-3.1.2/testsuite/test/java/org/jbos= s/test/ws/jaxws/samples/logicalhandler/SOAPEndpointSourceService.java 2010-= 03-26 14:21:36 UTC (rev 11869) @@ -0,0 +1,40 @@ +/* + * JBoss, Home of Professional Open Source. + * Copyright 2006, Red Hat Middleware LLC, and individual contributors + * as indicated by the @author tags. See the copyright.txt file in the + * distribution for a full listing of individual contributors. + * + * This is free software; you can redistribute it and/or modify it + * under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation; either version 2.1 of + * the License, or (at your option) any later version. + * + * This software is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this software; if not, write to the Free + * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA + * 02110-1301 USA, or see the FSF site: http://www.fsf.org. + */ +package org.jboss.test.ws.jaxws.samples.logicalhandler; + +import java.net.URL; + +import javax.jws.HandlerChain; +import javax.xml.namespace.QName; +import javax.xml.ws.Service; + +/** + * @author Richard Opalka + */ +(a)HandlerChain(file =3D "jaxws-client-source-handlers.xml") +public class SOAPEndpointSourceService extends Service +{ + public SOAPEndpointSourceService(URL wsdlLocation, QName serviceName) + { + super(wsdlLocation, serviceName); + } +} --===============5489380873345641682==--