JBossWS SVN: r11753 - in framework/trunk/testsuite/test: java/org/jboss/test/ws/jaxws and 7 other directories.
by jbossws-commits@lists.jboss.org
Author: jim.ma
Date: 2010-03-10 21:43:06 -0500 (Wed, 10 Mar 2010)
New Revision: 11753
Added:
framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/jbws2955/
framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/jbws2955/ClientSOAPHandler.java
framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/jbws2955/Endpoint.java
framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/jbws2955/EndpointImpl.java
framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/jbws2955/EndpointService.java
framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/jbws2955/JBWS2955TestCase.java
framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/jbws2955/client-handlers.xml
framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/jbws2956/
framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/jbws2956/ClientSOAPHandler.java
framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/jbws2956/JBWS2956TestCase.java
framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/jbws2956/OnewayEndpoint.java
framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/jbws2956/OnewayEndpointImpl.java
framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/jbws2956/OnewayEndpointService.java
framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/jbws2956/client-handlers.xml
framework/trunk/testsuite/test/resources/jaxws/jbws2955/
framework/trunk/testsuite/test/resources/jaxws/jbws2955/WEB-INF/
framework/trunk/testsuite/test/resources/jaxws/jbws2955/WEB-INF/jboss-web.xml
framework/trunk/testsuite/test/resources/jaxws/jbws2955/WEB-INF/web.xml
framework/trunk/testsuite/test/resources/jaxws/jbws2956/
framework/trunk/testsuite/test/resources/jaxws/jbws2956/WEB-INF/
framework/trunk/testsuite/test/resources/jaxws/jbws2956/WEB-INF/jboss-web.xml
framework/trunk/testsuite/test/resources/jaxws/jbws2956/WEB-INF/web.xml
Modified:
framework/trunk/testsuite/test/ant-import/build-jars-jaxws.xml
Log:
[JBWS-2955][JBWS-2956]:moved the tests to framework
Modified: framework/trunk/testsuite/test/ant-import/build-jars-jaxws.xml
===================================================================
--- framework/trunk/testsuite/test/ant-import/build-jars-jaxws.xml 2010-03-10 18:09:48 UTC (rev 11752)
+++ framework/trunk/testsuite/test/ant-import/build-jars-jaxws.xml 2010-03-11 02:43:06 UTC (rev 11753)
@@ -853,6 +853,29 @@
</fileset>
</jar>
+
+ <!-- jaxws-jbws2955 -->
+ <war warfile="${tests.output.dir}/test-libs/jaxws-jbws2955.war" webxml="${tests.output.dir}/test-resources/jaxws/jbws2955/WEB-INF/web.xml">
+ <classes dir="${tests.output.dir}/test-classes">
+ <include name="org/jboss/test/ws/jaxws/jbws2955/Endpoint.class"/>
+ <include name="org/jboss/test/ws/jaxws/jbws2955/EndpointImpl.class"/>
+ </classes>
+ <webinf dir="${tests.output.dir}/test-resources/jaxws/jbws2955/WEB-INF">
+ <include name="jboss-web.xml"/>
+ </webinf>
+ </war>
+
+ <!-- jaxws-jbws2956 -->
+ <war warfile="${tests.output.dir}/test-libs/jaxws-jbws2956.war" webxml="${tests.output.dir}/test-resources/jaxws/jbws2956/WEB-INF/web.xml">
+ <classes dir="${tests.output.dir}/test-classes">
+ <include name="org/jboss/test/ws/jaxws/jbws2956/OnewayEndpoint.class"/>
+ <include name="org/jboss/test/ws/jaxws/jbws2956/OnewayEndpointImpl.class"/>
+ </classes>
+ <webinf dir="${tests.output.dir}/test-resources/jaxws/jbws2956/WEB-INF">
+ <include name="jboss-web.xml"/>
+ </webinf>
+ </war>
+
<!-- jaxws namespace -->
<war warfile="${tests.output.dir}/test-libs/jaxws-namespace.war" webxml="${tests.output.dir}/test-resources/jaxws/namespace/WEB-INF/web.xml">
<classes dir="${tests.output.dir}/test-classes">
Added: framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/jbws2955/ClientSOAPHandler.java
===================================================================
--- framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/jbws2955/ClientSOAPHandler.java (rev 0)
+++ framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/jbws2955/ClientSOAPHandler.java 2010-03-11 02:43:06 UTC (rev 11753)
@@ -0,0 +1,77 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2008, 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.jbws2955;
+
+import javax.xml.soap.SOAPBody;
+import javax.xml.soap.SOAPElementFactory;
+import javax.xml.soap.SOAPException;
+import javax.xml.soap.SOAPMessage;
+import javax.xml.ws.handler.LogicalMessageContext;
+import javax.xml.ws.handler.MessageContext;
+import javax.xml.ws.handler.soap.SOAPMessageContext;
+
+import org.jboss.logging.Logger;
+import org.jboss.ws.WSException;
+import org.jboss.wsf.common.DOMWriter;
+import org.jboss.wsf.common.handler.GenericSOAPHandler;
+import org.w3c.dom.Document;
+import org.w3c.dom.Node;
+import org.w3c.dom.NodeList;
+
+public class ClientSOAPHandler extends GenericSOAPHandler<LogicalMessageContext>
+{
+ @Override
+ protected boolean handleInbound(final MessageContext msgContext)
+ {
+ try
+ {
+ SOAPMessageContext smc = (SOAPMessageContext) msgContext;
+ SOAPMessage message = smc.getMessage();
+
+ SOAPBody body = message.getSOAPBody();
+ Document document = body.extractContentAsDocument();
+ NodeList nodes = document.getChildNodes();
+ for (int i = 0; i < nodes.getLength(); i++)
+ {
+ Node current = nodes.item(i);
+
+ NodeList childNodes = current.getChildNodes();
+ for (int j = 0; j < childNodes.getLength(); j++)
+ {
+ Node currentChildNode = childNodes.item(j);
+ if ("return".equals(currentChildNode.getLocalName()))
+ {
+ currentChildNode.setTextContent("PutByClientSOAPHandler");
+ }
+ }
+ }
+ body.addDocument(document);
+ message.saveChanges();
+
+ }
+ catch (SOAPException e)
+ {
+ throw new WSException("Error in Handler", e);
+ }
+ return true;
+ }
+}
Added: framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/jbws2955/Endpoint.java
===================================================================
--- framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/jbws2955/Endpoint.java (rev 0)
+++ framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/jbws2955/Endpoint.java 2010-03-11 02:43:06 UTC (rev 11753)
@@ -0,0 +1,30 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2008, 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.jbws2955;
+import javax.jws.WebService;
+@WebService(name = "Endpoint", targetNamespace = "http://ws.jboss.org/jbws2955")
+public interface Endpoint
+{
+
+ public String echo(final String message);
+
+}
Added: framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/jbws2955/EndpointImpl.java
===================================================================
--- framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/jbws2955/EndpointImpl.java (rev 0)
+++ framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/jbws2955/EndpointImpl.java 2010-03-11 02:43:06 UTC (rev 11753)
@@ -0,0 +1,37 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2008, 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.jbws2955;
+
+import javax.jws.HandlerChain;
+import javax.jws.WebService;
+
+import org.jboss.logging.Logger;
+
+@WebService(name = "Endpoint", portName = "EndpointPort", serviceName="EndpointService", targetNamespace = "http://ws.jboss.org/jbws2955", endpointInterface = "org.jboss.test.ws.jaxws.jbws2955.Endpoint")
+public class EndpointImpl implements Endpoint
+{
+ public String echo(final String message)
+ {
+ return message;
+ }
+
+}
Added: framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/jbws2955/EndpointService.java
===================================================================
--- framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/jbws2955/EndpointService.java (rev 0)
+++ framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/jbws2955/EndpointService.java 2010-03-11 02:43:06 UTC (rev 11753)
@@ -0,0 +1,110 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2009, 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.jbws2955;
+
+import java.net.MalformedURLException;
+import java.net.URL;
+
+import javax.jws.HandlerChain;
+import javax.xml.namespace.QName;
+import javax.xml.ws.Service;
+import javax.xml.ws.WebEndpoint;
+import javax.xml.ws.WebServiceClient;
+import javax.xml.ws.WebServiceException;
+import javax.xml.ws.WebServiceFeature;
+
+@WebServiceClient(name = "EndpointService", targetNamespace = "http://ws.jboss.org/jbws2955")
+@HandlerChain(file = "client-handlers.xml")
+public class EndpointService
+ extends Service
+{
+
+ private final static URL ENDPOINTSERVICE_WSDL_LOCATION;
+ private final static WebServiceException ENDPOINTSERVICE_EXCEPTION;
+ private final static QName ENDPOINTSERVICE_QNAME = new QName("http://ws.jboss.org/jbws2955", "EndpointService");
+
+ static {
+ URL url = null;
+ WebServiceException e = null;
+ try {
+ url = new URL("http://localhost:8080/jaxws-jbws2955?wsdl");
+ } catch (MalformedURLException ex) {
+ e = new WebServiceException(ex);
+ }
+ ENDPOINTSERVICE_WSDL_LOCATION = url;
+ ENDPOINTSERVICE_EXCEPTION = e;
+ }
+
+ public EndpointService() {
+ super(__getWsdlLocation(), ENDPOINTSERVICE_QNAME);
+ }
+
+ public EndpointService(WebServiceFeature... features) {
+ super(__getWsdlLocation(), ENDPOINTSERVICE_QNAME, features);
+ }
+
+ public EndpointService(URL wsdlLocation) {
+ super(wsdlLocation, ENDPOINTSERVICE_QNAME);
+ }
+
+ public EndpointService(URL wsdlLocation, WebServiceFeature... features) {
+ super(wsdlLocation, ENDPOINTSERVICE_QNAME, features);
+ }
+
+ public EndpointService(URL wsdlLocation, QName serviceName) {
+ super(wsdlLocation, serviceName);
+ }
+
+ public EndpointService(URL wsdlLocation, QName serviceName, WebServiceFeature... features) {
+ super(wsdlLocation, serviceName, features);
+ }
+
+ /**
+ *
+ * @return
+ * returns Endpoint
+ */
+ @WebEndpoint(name = "EndpointPort")
+ public Endpoint getEndpointPort() {
+ return super.getPort(new QName("http://ws.jboss.org/jbws2955", "EndpointPort"), Endpoint.class);
+ }
+
+ /**
+ *
+ * @param features
+ * A list of {@link javax.xml.ws.WebServiceFeature} to configure on the proxy. Supported features not in the <code>features</code> parameter will have their default values.
+ * @return
+ * returns Endpoint
+ */
+ @WebEndpoint(name = "EndpointPort")
+ public Endpoint getEndpointPort(WebServiceFeature... features) {
+ return super.getPort(new QName("http://ws.jboss.org/jbws2955", "EndpointPort"), Endpoint.class, features);
+ }
+
+ private static URL __getWsdlLocation() {
+ if (ENDPOINTSERVICE_EXCEPTION!= null) {
+ throw ENDPOINTSERVICE_EXCEPTION;
+ }
+ return ENDPOINTSERVICE_WSDL_LOCATION;
+ }
+
+}
Added: framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/jbws2955/JBWS2955TestCase.java
===================================================================
--- framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/jbws2955/JBWS2955TestCase.java (rev 0)
+++ framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/jbws2955/JBWS2955TestCase.java 2010-03-11 02:43:06 UTC (rev 11753)
@@ -0,0 +1,73 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2009, 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.jbws2955;
+
+import java.net.URL;
+import java.util.Iterator;
+
+import javax.xml.namespace.QName;
+import javax.xml.soap.MessageFactory;
+import javax.xml.soap.SOAPBody;
+import javax.xml.soap.SOAPConnection;
+import javax.xml.soap.SOAPConnectionFactory;
+import javax.xml.soap.SOAPEnvelope;
+import javax.xml.soap.SOAPMessage;
+import javax.xml.ws.Service;
+
+import junit.framework.Test;
+
+import org.jboss.ws.core.soap.NodeImpl;
+
+import org.jboss.wsf.test.JBossWSTest;
+import org.jboss.wsf.test.JBossWSTestSetup;
+
+import org.w3c.dom.Node;
+import org.w3c.dom.NodeList;
+
+public class JBWS2955TestCase extends JBossWSTest
+{
+
+ public final String TARGET_ENDPOINT_ADDRESS = "http://" + getServerHost() + ":8080/jaxws-jbws2955";
+
+ private static Endpoint port;
+
+ public static Test suite() throws Exception
+ {
+ return new JBossWSTestSetup(JBWS2955TestCase.class, "jaxws-jbws2955.war");
+ }
+
+ public void setUp() throws Exception
+ {
+ super.setUp();
+ URL wsdlURL = new URL(TARGET_ENDPOINT_ADDRESS + "?wsdl");
+ QName serviceName = new QName("http://ws.jboss.org/jbws2955", "EndpointService");
+ EndpointService service = new EndpointService(wsdlURL);
+ port = service.getEndpointPort();
+ }
+
+ public void testCall() throws Exception
+ {
+
+ String response = port.echo("testJBWS2955");
+ assertEquals("PutByClientSOAPHandler", response);
+ }
+}
\ No newline at end of file
Added: framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/jbws2955/client-handlers.xml
===================================================================
--- framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/jbws2955/client-handlers.xml (rev 0)
+++ framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/jbws2955/client-handlers.xml 2010-03-11 02:43:06 UTC (rev 11753)
@@ -0,0 +1,13 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<handler-chains xmlns="http://java.sun.com/xml/ns/javaee"
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:ns1="http://org.jboss.ws/jaxws/samples/logicalhandler"
+ xsi:schemaLocation="http://java.sun.com/xml/ns/javaee javaee_web_services_1_2.xsd">
+ <handler-chain>
+ <port-name-pattern xmlns:ns1="http://ws.jboss.org/jbws2955">ns1:EndpointPort</port-name-pattern>
+ <handler>
+ <handler-name>ClientSOAPHandler</handler-name>
+ <handler-class>org.jboss.test.ws.jaxws.jbws2955.ClientSOAPHandler</handler-class>
+ </handler>
+ </handler-chain>
+</handler-chains>
\ No newline at end of file
Added: framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/jbws2956/ClientSOAPHandler.java
===================================================================
--- framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/jbws2956/ClientSOAPHandler.java (rev 0)
+++ framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/jbws2956/ClientSOAPHandler.java 2010-03-11 02:43:06 UTC (rev 11753)
@@ -0,0 +1,68 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2008, 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.jbws2956;
+
+import javax.xml.soap.MessageFactory;
+import javax.xml.soap.SOAPBody;
+import javax.xml.soap.SOAPException;
+import javax.xml.soap.SOAPFault;
+import javax.xml.soap.SOAPMessage;
+import javax.xml.ws.handler.LogicalMessageContext;
+import javax.xml.ws.handler.MessageContext;
+import javax.xml.ws.handler.soap.SOAPMessageContext;
+import javax.xml.ws.soap.SOAPFaultException;
+
+import org.jboss.ws.WSException;
+import org.jboss.ws.core.soap.MessageFactoryImpl;
+import org.jboss.ws.core.soap.SOAPMessageImpl;
+import org.jboss.wsf.common.handler.GenericSOAPHandler;
+import org.w3c.dom.Document;
+import org.w3c.dom.Node;
+import org.w3c.dom.NodeList;
+
+public class ClientSOAPHandler extends GenericSOAPHandler<LogicalMessageContext>
+{
+ @Override
+ protected boolean handleInbound(final MessageContext msgContext)
+ {
+ //do nothing
+ return true;
+ }
+
+ protected boolean handleOutbound(final MessageContext msgContext)
+ {
+ try
+ {
+ SOAPFault fault = null;
+ MessageFactoryImpl factory = new MessageFactoryImpl();
+ SOAPMessageImpl resMessage = (SOAPMessageImpl) factory.createMessage();
+ fault = resMessage.getSOAPBody().addFault();
+ fault.setFaultString("this is exception threwn by client outbound");
+ throw new SOAPFaultException(fault);
+ }
+ catch (SOAPException e)
+ {
+ //ignore
+ }
+ return true;
+ }
+}
Added: framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/jbws2956/JBWS2956TestCase.java
===================================================================
--- framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/jbws2956/JBWS2956TestCase.java (rev 0)
+++ framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/jbws2956/JBWS2956TestCase.java 2010-03-11 02:43:06 UTC (rev 11753)
@@ -0,0 +1,72 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2009, 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.jbws2956;
+
+import java.net.URL;
+import java.util.Iterator;
+
+import javax.xml.namespace.QName;
+import javax.xml.soap.MessageFactory;
+import javax.xml.soap.SOAPBody;
+import javax.xml.soap.SOAPConnection;
+import javax.xml.soap.SOAPConnectionFactory;
+import javax.xml.soap.SOAPEnvelope;
+import javax.xml.soap.SOAPMessage;
+import javax.xml.ws.Service;
+
+import junit.framework.Test;
+
+import org.jboss.ws.core.soap.NodeImpl;
+
+import org.jboss.wsf.test.JBossWSTest;
+import org.jboss.wsf.test.JBossWSTestSetup;
+
+import org.w3c.dom.Node;
+import org.w3c.dom.NodeList;
+
+public class JBWS2956TestCase extends JBossWSTest
+{
+
+ public final String TARGET_ENDPOINT_ADDRESS = "http://" + getServerHost() + ":8080/jaxws-jbws2956";
+
+ private static OnewayEndpoint port;
+
+ public static Test suite() throws Exception
+ {
+ return new JBossWSTestSetup(JBWS2956TestCase.class, "jaxws-jbws2956.war");
+ }
+
+ public void setUp() throws Exception
+ {
+ super.setUp();
+ URL wsdlURL = new URL(TARGET_ENDPOINT_ADDRESS + "?wsdl");
+ QName serviceName = new QName("http://ws.jboss.org/jbws2956", "EndpointService");
+ OnewayEndpointService service = new OnewayEndpointService(wsdlURL);
+ port = service.getOnewayEndpointPort();
+ }
+
+ public void testCall() throws Exception
+ {
+ //there should be no exception threw
+ port.echo("testJBWS2956");
+ }
+}
\ No newline at end of file
Added: framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/jbws2956/OnewayEndpoint.java
===================================================================
--- framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/jbws2956/OnewayEndpoint.java (rev 0)
+++ framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/jbws2956/OnewayEndpoint.java 2010-03-11 02:43:06 UTC (rev 11753)
@@ -0,0 +1,31 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2008, 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.jbws2956;
+import javax.jws.Oneway;
+import javax.jws.WebService;
+@WebService(name = "Endpoint", targetNamespace = "http://ws.jboss.org/jbws2956")
+public interface OnewayEndpoint
+{
+ @Oneway
+ public void echo(final String message);
+
+}
Added: framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/jbws2956/OnewayEndpointImpl.java
===================================================================
--- framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/jbws2956/OnewayEndpointImpl.java (rev 0)
+++ framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/jbws2956/OnewayEndpointImpl.java 2010-03-11 02:43:06 UTC (rev 11753)
@@ -0,0 +1,36 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2008, 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.jbws2956;
+
+import javax.jws.HandlerChain;
+import javax.jws.WebService;
+
+
+@WebService(name = "Endpoint", portName = "EndpointPort", serviceName="EndpointService", targetNamespace = "http://ws.jboss.org/jbws2956", endpointInterface = "org.jboss.test.ws.jaxws.jbws2956.OnewayEndpoint")
+public class OnewayEndpointImpl implements OnewayEndpoint
+{
+ public void echo(final String message)
+ {
+ System.out.println("incoming message : " + message);
+ }
+
+}
Added: framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/jbws2956/OnewayEndpointService.java
===================================================================
--- framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/jbws2956/OnewayEndpointService.java (rev 0)
+++ framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/jbws2956/OnewayEndpointService.java 2010-03-11 02:43:06 UTC (rev 11753)
@@ -0,0 +1,99 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2009, 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.jbws2956;
+
+import java.net.MalformedURLException;
+import java.net.URL;
+
+import javax.jws.HandlerChain;
+import javax.xml.namespace.QName;
+import javax.xml.ws.Service;
+import javax.xml.ws.WebEndpoint;
+import javax.xml.ws.WebServiceClient;
+import javax.xml.ws.WebServiceException;
+import javax.xml.ws.WebServiceFeature;
+
+@WebServiceClient(name = "EndpointService", targetNamespace = "http://ws.jboss.org/jbws2956")
+@HandlerChain(file = "client-handlers.xml")
+public class OnewayEndpointService
+ extends Service
+{
+
+ private final static URL ENDPOINTSERVICE_WSDL_LOCATION;
+ private final static WebServiceException ENDPOINTSERVICE_EXCEPTION;
+ private final static QName ENDPOINTSERVICE_QNAME = new QName("http://ws.jboss.org/jbws2956", "EndpointService");
+
+ static {
+ URL url = null;
+ WebServiceException e = null;
+ try {
+ url = new URL("http://localhost:8080/jaxws-jbws2955?wsdl");
+ } catch (MalformedURLException ex) {
+ e = new WebServiceException(ex);
+ }
+ ENDPOINTSERVICE_WSDL_LOCATION = url;
+ ENDPOINTSERVICE_EXCEPTION = e;
+ }
+
+ public OnewayEndpointService() {
+ super(__getWsdlLocation(), ENDPOINTSERVICE_QNAME);
+ }
+
+
+ public OnewayEndpointService(URL wsdlLocation) {
+ super(wsdlLocation, ENDPOINTSERVICE_QNAME);
+ }
+
+ public OnewayEndpointService(URL wsdlLocation, QName serviceName) {
+ super(wsdlLocation, serviceName);
+ }
+
+ /**
+ *
+ * @return
+ * returns Endpoint
+ */
+ @WebEndpoint(name = "EndpointPort")
+ public OnewayEndpoint getOnewayEndpointPort() {
+ return super.getPort(new QName("http://ws.jboss.org/jbws2956", "EndpointPort"), OnewayEndpoint.class);
+ }
+
+ /**
+ *
+ * @param features
+ * A list of {@link javax.xml.ws.WebServiceFeature} to configure on the proxy. Supported features not in the <code>features</code> parameter will have their default values.
+ * @return
+ * returns Endpoint
+ */
+ @WebEndpoint(name = "EndpointPort")
+ public OnewayEndpoint getOnewayEndpointPort(WebServiceFeature... features) {
+ return super.getPort(new QName("http://ws.jboss.org/jbws2956", "EndpointPort"), OnewayEndpoint.class, features);
+ }
+
+ private static URL __getWsdlLocation() {
+ if (ENDPOINTSERVICE_EXCEPTION!= null) {
+ throw ENDPOINTSERVICE_EXCEPTION;
+ }
+ return ENDPOINTSERVICE_WSDL_LOCATION;
+ }
+
+}
Added: framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/jbws2956/client-handlers.xml
===================================================================
--- framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/jbws2956/client-handlers.xml (rev 0)
+++ framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/jbws2956/client-handlers.xml 2010-03-11 02:43:06 UTC (rev 11753)
@@ -0,0 +1,13 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<handler-chains xmlns="http://java.sun.com/xml/ns/javaee"
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:ns1="http://org.jboss.ws/jaxws/samples/logicalhandler"
+ xsi:schemaLocation="http://java.sun.com/xml/ns/javaee javaee_web_services_1_2.xsd">
+ <handler-chain>
+ <port-name-pattern xmlns:ns1="http://ws.jboss.org/jbws2956">ns1:EndpointPort</port-name-pattern>
+ <handler>
+ <handler-name>ClientSOAPHandler</handler-name>
+ <handler-class>org.jboss.test.ws.jaxws.jbws2956.ClientSOAPHandler</handler-class>
+ </handler>
+ </handler-chain>
+</handler-chains>
\ No newline at end of file
Added: framework/trunk/testsuite/test/resources/jaxws/jbws2955/WEB-INF/jboss-web.xml
===================================================================
--- framework/trunk/testsuite/test/resources/jaxws/jbws2955/WEB-INF/jboss-web.xml (rev 0)
+++ framework/trunk/testsuite/test/resources/jaxws/jbws2955/WEB-INF/jboss-web.xml 2010-03-11 02:43:06 UTC (rev 11753)
@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<!DOCTYPE jboss-web PUBLIC "-//JBoss//DTD Web Application 2.4//EN" "http://www.jboss.org/j2ee/dtd/jboss-web_4_0.dtd">
+
+<jboss-web>
+ <context-root>/jaxws-jbws2955</context-root>
+</jboss-web>
\ No newline at end of file
Added: framework/trunk/testsuite/test/resources/jaxws/jbws2955/WEB-INF/web.xml
===================================================================
--- framework/trunk/testsuite/test/resources/jaxws/jbws2955/WEB-INF/web.xml (rev 0)
+++ framework/trunk/testsuite/test/resources/jaxws/jbws2955/WEB-INF/web.xml 2010-03-11 02:43:06 UTC (rev 11753)
@@ -0,0 +1,16 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<web-app version="2.4" xmlns="http://java.sun.com/xml/ns/j2ee"
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd">
+
+ <servlet>
+ <servlet-name>Endpoint</servlet-name>
+ <servlet-class>org.jboss.test.ws.jaxws.jbws2955.EndpointImpl</servlet-class>
+ </servlet>
+
+ <servlet-mapping>
+ <servlet-name>Endpoint</servlet-name>
+ <url-pattern>/*</url-pattern>
+ </servlet-mapping>
+
+</web-app>
\ No newline at end of file
Added: framework/trunk/testsuite/test/resources/jaxws/jbws2956/WEB-INF/jboss-web.xml
===================================================================
--- framework/trunk/testsuite/test/resources/jaxws/jbws2956/WEB-INF/jboss-web.xml (rev 0)
+++ framework/trunk/testsuite/test/resources/jaxws/jbws2956/WEB-INF/jboss-web.xml 2010-03-11 02:43:06 UTC (rev 11753)
@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<!DOCTYPE jboss-web PUBLIC "-//JBoss//DTD Web Application 2.4//EN" "http://www.jboss.org/j2ee/dtd/jboss-web_4_0.dtd">
+
+<jboss-web>
+ <context-root>/jaxws-jbws2956</context-root>
+</jboss-web>
\ No newline at end of file
Added: framework/trunk/testsuite/test/resources/jaxws/jbws2956/WEB-INF/web.xml
===================================================================
--- framework/trunk/testsuite/test/resources/jaxws/jbws2956/WEB-INF/web.xml (rev 0)
+++ framework/trunk/testsuite/test/resources/jaxws/jbws2956/WEB-INF/web.xml 2010-03-11 02:43:06 UTC (rev 11753)
@@ -0,0 +1,16 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<web-app version="2.4" xmlns="http://java.sun.com/xml/ns/j2ee"
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd">
+
+ <servlet>
+ <servlet-name>Endpoint</servlet-name>
+ <servlet-class>org.jboss.test.ws.jaxws.jbws2956.OnewayEndpointImpl</servlet-class>
+ </servlet>
+
+ <servlet-mapping>
+ <servlet-name>Endpoint</servlet-name>
+ <url-pattern>/*</url-pattern>
+ </servlet-mapping>
+
+</web-app>
\ No newline at end of file
14 years, 9 months
JBossWS SVN: r11752 - stack/native/trunk.
by jbossws-commits@lists.jboss.org
Author: alessio.soldano(a)jboss.com
Date: 2010-03-10 13:09:48 -0500 (Wed, 10 Mar 2010)
New Revision: 11752
Modified:
stack/native/trunk/pom.xml
Log:
[JBWS-2959] Explicit dependency on jboss-common-core / jboss-common does not seem to be required at all
Modified: stack/native/trunk/pom.xml
===================================================================
--- stack/native/trunk/pom.xml 2010-03-10 17:50:01 UTC (rev 11751)
+++ stack/native/trunk/pom.xml 2010-03-10 18:09:48 UTC (rev 11752)
@@ -66,7 +66,6 @@
<jsr181.api.version>1.0-MR1</jsr181.api.version>
<jaxb.api.version>2.2</jaxb.api.version>
<jaxb.impl.version>2.2</jaxb.impl.version>
- <jboss.common.version>2.2.16.GA</jboss.common.version>
<jboss.logging.version>2.2.0.CR1</jboss.logging.version>
<jboss.jaxr.version>2.0.1</jboss.jaxr.version>
<apache.scout.version>1.1.1</apache.scout.version>
@@ -198,11 +197,6 @@
<artifactId>javassist</artifactId>
<version>${javassist.version}</version>
</dependency>
- <dependency>
- <groupId>jboss.common</groupId>
- <artifactId>jboss-common</artifactId>
- <version>${jboss.common.version}</version>
- </dependency>
<!-- transitive dependencies -->
<dependency>
<groupId>commons-logging</groupId>
14 years, 9 months
JBossWS SVN: r11751 - in common/trunk/src: test/java/org/jboss/test/ws/common and 1 other directory.
by jbossws-commits@lists.jboss.org
Author: darran.lofthouse(a)jboss.com
Date: 2010-03-10 12:50:01 -0500 (Wed, 10 Mar 2010)
New Revision: 11751
Added:
common/trunk/src/test/java/org/jboss/test/ws/common/NormalizerTestCase.java
Modified:
common/trunk/src/main/java/org/jboss/wsf/common/Normalizer.java
Log:
[JBWS-2885] CDATA Responses Being Incorrectly Escaped.
Modified: common/trunk/src/main/java/org/jboss/wsf/common/Normalizer.java
===================================================================
--- common/trunk/src/main/java/org/jboss/wsf/common/Normalizer.java 2010-03-10 17:27:01 UTC (rev 11750)
+++ common/trunk/src/main/java/org/jboss/wsf/common/Normalizer.java 2010-03-10 17:50:01 UTC (rev 11751)
@@ -28,13 +28,18 @@
*
* @author <a href="mailto:mvecera@redhat.com">Martin Vecera</a>
* @author <a href="mailto:alessio.soldano@jboss.com">Alessio Soldano</a>
+* @author <a href="mailto:darran.lofthouse@jboss.com">Darran Lofthouse</a>
+*
* @since 09-Dic-2009
-*
*/
final public class Normalizer
{
private static final Pattern PATTERN = Pattern.compile("[&<>'\"\r\n]");
+ private static final String CDATA_START = "<![CDATA[";
+
+ private static final String CDATA_END = "]]>";
+
public static String normalize(String strValue)
{
return normalize(strValue, false);
@@ -45,11 +50,57 @@
Matcher m = PATTERN.matcher(strValue);
if (m.find())
{
+ int len = strValue.length();
+ StringBuilder sb = new StringBuilder(len * 3); // faster than StringBuffer, not thread safe
+ int start = 0;
+
+ while (start < len)
+ {
+ int cdataStart = strValue.indexOf(CDATA_START, start);
+ if (cdataStart > -1)
+ {
+ int cdataEnd = strValue.indexOf(CDATA_END, cdataStart);
+ // If a valid start and end to a <![CDATA[ ]]> section are
+ // identified exclude from normalisation.
+ if (cdataEnd > -1)
+ {
+ if (cdataStart > start)
+ {
+ normalize(strValue.substring(start, cdataStart), canonical, sb);
+ }
+ sb.append(strValue.subSequence(cdataStart, cdataEnd + 3));
+ start = cdataEnd + 3;
+ }
+ else
+ {
+ normalize(strValue.substring(start, len), canonical, sb);
+ start = len;
+ }
+ }
+ else
+ {
+ normalize(strValue.substring(start, len), canonical, sb);
+ start = len;
+ }
+ }
+
+ return sb.toString();
+ }
+ else
+ {
+ return strValue;
+ }
+ }
+
+ private static void normalize(String strValue, boolean canonical, StringBuilder sb)
+ {
+ Matcher m = PATTERN.matcher(strValue);
+ if (m.find())
+ {
int pos = m.start(); // we can use previous match to skip some part at the string beginning
int len = strValue.length(); // just a single call to length()
char[] input = new char[len]; // this is to ommit calls to String.charAt()
strValue.getChars(0, len, input, 0);
- StringBuilder sb = new StringBuilder(len * 3); // faster than StringBuffer, not thread safe
int copyStart = 0;
@@ -119,12 +170,10 @@
{
sb.append(input, copyStart, len - copyStart);
}
-
- return sb.toString();
}
else
{
- return strValue;
+ sb.append(strValue);
}
}
}
Added: common/trunk/src/test/java/org/jboss/test/ws/common/NormalizerTestCase.java
===================================================================
--- common/trunk/src/test/java/org/jboss/test/ws/common/NormalizerTestCase.java (rev 0)
+++ common/trunk/src/test/java/org/jboss/test/ws/common/NormalizerTestCase.java 2010-03-10 17:50:01 UTC (rev 11751)
@@ -0,0 +1,104 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2010, 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.common;
+
+import org.jboss.wsf.common.Normalizer;
+
+import junit.framework.TestCase;
+
+/**
+ * [JBWS-2885] http://jira.jboss.com/jira/browse/JBWS-2885
+ *
+ * Test case to test <![CDATA[ ]]> sections are skipped in the
+ * normalization process.
+ *
+ * @author darran.lofthouse(a)jboss.com
+ * @since Mar 10, 2010
+ */
+public class NormalizerTestCase extends TestCase
+{
+
+ private static final String CDATA_STRING = "<![CDATA[ABC]]>";
+
+ public void testCDATAOnly()
+ {
+ String normalized = Normalizer.normalize(CDATA_STRING);
+
+ assertEquals("Normalized String", CDATA_STRING, normalized);
+ }
+
+ public void testCDATABegin()
+ {
+ String normalized = Normalizer.normalize(CDATA_STRING + "ABC");
+
+ assertEquals("Normalized String", CDATA_STRING + "ABC", normalized);
+ }
+
+ public void testCDATAEnd()
+ {
+ String normalized = Normalizer.normalize("ABD" + CDATA_STRING);
+
+ assertEquals("Normalized String", "ABD" + CDATA_STRING, normalized);
+ }
+
+ public void testCDATAMid()
+ {
+ String normalized = Normalizer.normalize("ABD" + CDATA_STRING + "EFG");
+
+ assertEquals("Normalized String", "ABD" + CDATA_STRING + "EFG", normalized);
+ }
+
+ public void testCDATADouble()
+ {
+ String normalized = Normalizer.normalize("ABD" + CDATA_STRING + "EFG" + CDATA_STRING + "HIJ");
+
+ assertEquals("Normalized String", "ABD" + CDATA_STRING + "EFG" + CDATA_STRING + "HIJ", normalized);
+ }
+
+ public void testCDATABegin_Replace()
+ {
+ String normalized = Normalizer.normalize(CDATA_STRING + "<>");
+
+ assertEquals("Normalized String", CDATA_STRING + "<>", normalized);
+ }
+
+ public void testCDATAEnd_Replace()
+ {
+ String normalized = Normalizer.normalize("<>" + CDATA_STRING);
+
+ assertEquals("Normalized String", "<>" + CDATA_STRING, normalized);
+ }
+
+ public void testCDATAMid_Replace()
+ {
+ String normalized = Normalizer.normalize("<>" + CDATA_STRING + "<>");
+
+ assertEquals("Normalized String", "<>" + CDATA_STRING + "<>", normalized);
+ }
+
+ public void testCDATADouble_Replace()
+ {
+ String normalized = Normalizer.normalize("<>" + CDATA_STRING + "<>" + CDATA_STRING + "<>");
+
+ assertEquals("Normalized String", "<>" + CDATA_STRING + "<>" + CDATA_STRING + "<>", normalized);
+ }
+}
Property changes on: common/trunk/src/test/java/org/jboss/test/ws/common/NormalizerTestCase.java
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
14 years, 9 months
JBossWS SVN: r11750 - in stack/native/trunk: modules/core and 1 other directory.
by jbossws-commits@lists.jboss.org
Author: alessio.soldano(a)jboss.com
Date: 2010-03-10 12:27:01 -0500 (Wed, 10 Mar 2010)
New Revision: 11750
Modified:
stack/native/trunk/modules/core/pom.xml
stack/native/trunk/pom.xml
Log:
[JBWS-2959] Updating jbossxb and jboss-common-core dependencies
Modified: stack/native/trunk/modules/core/pom.xml
===================================================================
--- stack/native/trunk/modules/core/pom.xml 2010-03-10 17:19:18 UTC (rev 11749)
+++ stack/native/trunk/modules/core/pom.xml 2010-03-10 17:27:01 UTC (rev 11750)
@@ -16,6 +16,7 @@
<properties>
<jboss.jbosssx.version>2.0.2.SP3</jboss.jbosssx.version>
<jboss.microcontainer.version>2.0.2.GA</jboss.microcontainer.version>
+ <jboss.jbossxb.version>2.0.1.GA</jboss.jbossxb.version>
</properties>
<!-- Dependencies -->
@@ -84,7 +85,7 @@
<groupId>org.jboss</groupId>
<artifactId>jbossxb</artifactId>
<scope>provided</scope>
- <version>1.0.0.SP2</version>
+ <version>${jboss.jbossxb.version}</version>
</dependency>
<dependency>
<groupId>xerces</groupId>
Modified: stack/native/trunk/pom.xml
===================================================================
--- stack/native/trunk/pom.xml 2010-03-10 17:19:18 UTC (rev 11749)
+++ stack/native/trunk/pom.xml 2010-03-10 17:27:01 UTC (rev 11750)
@@ -66,7 +66,7 @@
<jsr181.api.version>1.0-MR1</jsr181.api.version>
<jaxb.api.version>2.2</jaxb.api.version>
<jaxb.impl.version>2.2</jaxb.impl.version>
- <jboss.common.version>1.2.1.GA</jboss.common.version>
+ <jboss.common.version>2.2.16.GA</jboss.common.version>
<jboss.logging.version>2.2.0.CR1</jboss.logging.version>
<jboss.jaxr.version>2.0.1</jboss.jaxr.version>
<apache.scout.version>1.1.1</apache.scout.version>
14 years, 9 months
JBossWS SVN: r11749 - stack/cxf/trunk.
by jbossws-commits@lists.jboss.org
Author: alessio.soldano(a)jboss.com
Date: 2010-03-10 12:19:18 -0500 (Wed, 10 Mar 2010)
New Revision: 11749
Modified:
stack/cxf/trunk/pom.xml
Log:
[JBWS-2959] Updating jboss-common-core dependency
Modified: stack/cxf/trunk/pom.xml
===================================================================
--- stack/cxf/trunk/pom.xml 2010-03-10 15:51:34 UTC (rev 11748)
+++ stack/cxf/trunk/pom.xml 2010-03-10 17:19:18 UTC (rev 11749)
@@ -59,7 +59,7 @@
<cxf.stax.version>1.0.1</cxf.stax.version>
<cxf.asm.version>2.2.3</cxf.asm.version>
<fastinfoset.api.version>1.2.7</fastinfoset.api.version>
- <jboss.common.core.version>2.2.14.GA</jboss.common.core.version>
+ <jboss.common.core.version>2.2.16.GA</jboss.common.core.version>
<jaxb.api.version>2.1</jaxb.api.version>
<jaxb.impl.version>2.1.12</jaxb.impl.version>
<jaxrpc.api.version>1.1</jaxrpc.api.version>
14 years, 9 months
JBossWS SVN: r11748 - stack/metro/trunk.
by jbossws-commits@lists.jboss.org
Author: alessio.soldano(a)jboss.com
Date: 2010-03-10 10:51:34 -0500 (Wed, 10 Mar 2010)
New Revision: 11748
Modified:
stack/metro/trunk/pom.xml
Log:
[JBWS-2958] Move to wsdl4j 1.6.2
Modified: stack/metro/trunk/pom.xml
===================================================================
--- stack/metro/trunk/pom.xml 2010-03-10 15:51:03 UTC (rev 11747)
+++ stack/metro/trunk/pom.xml 2010-03-10 15:51:34 UTC (rev 11748)
@@ -71,7 +71,7 @@
<sun.wsit.version>1.3.1</sun.wsit.version>
<sun.saaj.impl.version>1.3.3</sun.saaj.impl.version>
<woodstox.version>3.2.6</woodstox.version>
- <wsdl4j.version>1.6.1</wsdl4j.version>
+ <wsdl4j.version>1.6.2</wsdl4j.version>
<jsr181.version>1.0-MR1</jsr181.version>
<jsr250.version>1.0</jsr250.version>
</properties>
14 years, 9 months
JBossWS SVN: r11747 - stack/native/trunk.
by jbossws-commits@lists.jboss.org
Author: alessio.soldano(a)jboss.com
Date: 2010-03-10 10:51:03 -0500 (Wed, 10 Mar 2010)
New Revision: 11747
Modified:
stack/native/trunk/pom.xml
Log:
[JBWS-2958] Move to wsdl4j 1.6.2
Modified: stack/native/trunk/pom.xml
===================================================================
--- stack/native/trunk/pom.xml 2010-03-10 13:50:26 UTC (rev 11746)
+++ stack/native/trunk/pom.xml 2010-03-10 15:51:03 UTC (rev 11747)
@@ -77,7 +77,7 @@
<sun.policy.version>2.0-b01</sun.policy.version>
<woodstox.version>3.2.6</woodstox.version>
<wscommons.policy.version>1.0</wscommons.policy.version>
- <wsdl4j.version>1.6.1</wsdl4j.version>
+ <wsdl4j.version>1.6.2</wsdl4j.version>
<xmlsec.version>1.4.3</xmlsec.version>
<xerces.version>2.9.1</xerces.version>
</properties>
14 years, 9 months
JBossWS SVN: r11746 - stack/native/trunk/modules/core/src/main/java/org/jboss/wsf/stack/jbws.
by jbossws-commits@lists.jboss.org
Author: richard.opalka(a)jboss.com
Date: 2010-03-10 08:50:26 -0500 (Wed, 10 Mar 2010)
New Revision: 11746
Modified:
stack/native/trunk/modules/core/src/main/java/org/jboss/wsf/stack/jbws/WSDLFilePublisher.java
Log:
including vfszip protocol in WSDL handling
Modified: stack/native/trunk/modules/core/src/main/java/org/jboss/wsf/stack/jbws/WSDLFilePublisher.java
===================================================================
--- stack/native/trunk/modules/core/src/main/java/org/jboss/wsf/stack/jbws/WSDLFilePublisher.java 2010-03-10 12:46:47 UTC (rev 11745)
+++ stack/native/trunk/modules/core/src/main/java/org/jboss/wsf/stack/jbws/WSDLFilePublisher.java 2010-03-10 13:50:26 UTC (rev 11746)
@@ -369,7 +369,7 @@
wsdlLocation = wsdlLocation.substring(wsdlLocation.indexOf(expLocation) + expLocation.length());
wsdlFile = new File(locationFile + "/" + wsdlLocation);
}
- else if (wsdlLocation.startsWith("vfsfile:") || wsdlLocation.startsWith("file:") || wsdlLocation.startsWith("jar:"))
+ else if (wsdlLocation.startsWith("vfsfile:") || wsdlLocation.startsWith("file:") || wsdlLocation.startsWith("jar:") || wsdlLocation.startsWith("vfszip:"))
{
wsdlLocation = wsdlLocation.substring(wsdlLocation.lastIndexOf("/") + 1);
wsdlFile = new File(locationFile + "/" + wsdlLocation);
14 years, 9 months
JBossWS SVN: r11745 - stack/native/trunk/modules/testsuite.
by jbossws-commits@lists.jboss.org
Author: alessio.soldano(a)jboss.com
Date: 2010-03-10 07:46:47 -0500 (Wed, 10 Mar 2010)
New Revision: 11745
Modified:
stack/native/trunk/modules/testsuite/pom.xml
Log:
[JBWS-2948] Updating java.protocol.handler.pkgs configuration
Modified: stack/native/trunk/modules/testsuite/pom.xml
===================================================================
--- stack/native/trunk/modules/testsuite/pom.xml 2010-03-10 12:45:34 UTC (rev 11744)
+++ stack/native/trunk/modules/testsuite/pom.xml 2010-03-10 12:46:47 UTC (rev 11745)
@@ -173,7 +173,7 @@
</property>
<property>
<name>java.protocol.handler.pkgs</name>
- <value>org.jboss.virtual.protocol</value>
+ <value>org.jboss.net.protocol|org.jboss.vfs.protocol|org.jboss.virtual.protocol</value>
</property>
<property>
<name>java.util.logging.manager</name>
14 years, 9 months
JBossWS SVN: r11744 - stack/cxf/trunk/modules/testsuite.
by jbossws-commits@lists.jboss.org
Author: alessio.soldano(a)jboss.com
Date: 2010-03-10 07:45:34 -0500 (Wed, 10 Mar 2010)
New Revision: 11744
Modified:
stack/cxf/trunk/modules/testsuite/pom.xml
Log:
[JBWS-2948] Updating java.protocol.handler.pkgs configuration
Modified: stack/cxf/trunk/modules/testsuite/pom.xml
===================================================================
--- stack/cxf/trunk/modules/testsuite/pom.xml 2010-03-10 12:44:43 UTC (rev 11743)
+++ stack/cxf/trunk/modules/testsuite/pom.xml 2010-03-10 12:45:34 UTC (rev 11744)
@@ -169,7 +169,7 @@
</property>
<property>
<name>java.protocol.handler.pkgs</name>
- <value>org.jboss.virtual.protocol</value>
+ <value>org.jboss.net.protocol|org.jboss.vfs.protocol|org.jboss.virtual.protocol</value>
</property>
<property>
<name>java.util.logging.manager</name>
14 years, 9 months