Author: ropalka
Date: 2011-12-16 05:21:17 -0500 (Fri, 16 Dec 2011)
New Revision: 15402
Added:
shared-testsuite/trunk/testsuite/src/test/java/org/jboss/test/ws/jaxws/jbws3401/
shared-testsuite/trunk/testsuite/src/test/java/org/jboss/test/ws/jaxws/jbws3401/JBWS3401TestCase.java
shared-testsuite/trunk/testsuite/src/test/java/org/jboss/test/ws/jaxws/jbws3401/TestEndpoint.java
shared-testsuite/trunk/testsuite/src/test/java/org/jboss/test/ws/jaxws/jbws3401/TestEndpointImpl.java
shared-testsuite/trunk/testsuite/src/test/resources/jaxws/jbws3401/
shared-testsuite/trunk/testsuite/src/test/resources/jaxws/jbws3401/WEB-INF/
shared-testsuite/trunk/testsuite/src/test/resources/jaxws/jbws3401/WEB-INF/wsdl/
shared-testsuite/trunk/testsuite/src/test/resources/jaxws/jbws3401/WEB-INF/wsdl/TestService.wsdl
shared-testsuite/trunk/testsuite/src/test/resources/jaxws/jbws3401/WEB-INF/wsdl/schema1.xsd
shared-testsuite/trunk/testsuite/src/test/resources/jaxws/jbws3401/WEB-INF/wsdl/schema2.xsd
shared-testsuite/trunk/testsuite/src/test/resources/jaxws/jbws3401/WEB-INF/wsdl/schema3.xsd
shared-testsuite/trunk/testsuite/src/test/resources/jaxws/jbws3401/WEB-INF/wsdl/schema4.xsd
shared-testsuite/trunk/testsuite/src/test/resources/jaxws/jbws3401/WEB-INF/wsdl/schema5.xsd
Modified:
shared-testsuite/trunk/testsuite/src/test/ant-import/build-jars-jaxws.xml
Log:
[JBWS-3401] providing test case
Modified: shared-testsuite/trunk/testsuite/src/test/ant-import/build-jars-jaxws.xml
===================================================================
--- shared-testsuite/trunk/testsuite/src/test/ant-import/build-jars-jaxws.xml 2011-12-15
23:54:03 UTC (rev 15401)
+++ shared-testsuite/trunk/testsuite/src/test/ant-import/build-jars-jaxws.xml 2011-12-16
10:21:17 UTC (rev 15402)
@@ -1133,6 +1133,17 @@
</classes>
</war>
+ <!-- jaxws-jbws3401 -->
+ <war warfile="${tests.output.dir}/test-libs/jaxws-jbws3401.war"
needxmlfile="false">
+ <classes dir="${tests.output.dir}/test-classes">
+ <include name="org/jboss/test/ws/jaxws/jbws3401/*.class" />
+ <exclude name="org/jboss/test/ws/jaxws/jbws3401/*TestCase.class" />
+ </classes>
+ <webinf
dir="${tests.output.dir}/test-resources/jaxws/jbws3401/WEB-INF">
+ <include name="wsdl/*" />
+ </webinf>
+ </war>
+
<!-- jaxws-as2961 -->
<war warfile="${tests.output.dir}/test-libs/jaxws-as2961.war"
webxml="${tests.output.dir}/test-resources/jaxws/as2961/WEB-INF/web.xml">
<classes dir="${tests.output.dir}/test-classes">
Added:
shared-testsuite/trunk/testsuite/src/test/java/org/jboss/test/ws/jaxws/jbws3401/JBWS3401TestCase.java
===================================================================
---
shared-testsuite/trunk/testsuite/src/test/java/org/jboss/test/ws/jaxws/jbws3401/JBWS3401TestCase.java
(rev 0)
+++
shared-testsuite/trunk/testsuite/src/test/java/org/jboss/test/ws/jaxws/jbws3401/JBWS3401TestCase.java 2011-12-16
10:21:17 UTC (rev 15402)
@@ -0,0 +1,65 @@
+/*
+* JBoss, Home of Professional Open Source.
+* Copyright 2011, 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.jbws3401;
+
+import java.net.URL;
+
+import javax.xml.namespace.QName;
+import javax.xml.ws.Service;
+
+import junit.framework.Test;
+
+import org.jboss.wsf.test.JBossWSTest;
+import org.jboss.wsf.test.JBossWSTestSetup;
+
+/**
+ * [JBWS-3401] Support for EJBs bundled in .war archives referencing schemas.
+ *
+ * @author <a href="mailto:ropalka@redhat.com">Richard Opalka</a>
+ */
+public class JBWS3401TestCase extends JBossWSTest
+{
+
+ public static Test suite() throws Exception
+ {
+ return new JBossWSTestSetup(JBWS3401TestCase.class,
"jaxws-jbws3401.war");
+ }
+
+ private TestEndpoint getPort() throws Exception
+ {
+
+ URL wsdlURL = new URL("http://" + getServerHost() +
":8080/jaxws-jbws3401/TestEndpointService/TestEndpoint?wsdl");
+ QName serviceName = new QName("http://org.jboss.test.ws/jbws3401",
"TestEndpointService");
+
+ Service service = Service.create(wsdlURL, serviceName);
+
+ return service.getPort(TestEndpoint.class);
+ }
+
+ public void testCall() throws Exception
+ {
+ String message = "Hi";
+ String response = getPort().echo(message);
+ assertEquals(message, response);
+ }
+
+}
Added:
shared-testsuite/trunk/testsuite/src/test/java/org/jboss/test/ws/jaxws/jbws3401/TestEndpoint.java
===================================================================
---
shared-testsuite/trunk/testsuite/src/test/java/org/jboss/test/ws/jaxws/jbws3401/TestEndpoint.java
(rev 0)
+++
shared-testsuite/trunk/testsuite/src/test/java/org/jboss/test/ws/jaxws/jbws3401/TestEndpoint.java 2011-12-16
10:21:17 UTC (rev 15402)
@@ -0,0 +1,35 @@
+/*
+* JBoss, Home of Professional Open Source.
+* Copyright 2011, 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.jbws3401;
+
+import javax.jws.WebService;
+
+/**
+ * @author <a href="mailto:ropalka@redhat.com">Richard Opalka</a>
+ */
+@WebService(name = "TestEndpoint", targetNamespace =
"http://org.jboss.test.ws/jbws3401")
+public interface TestEndpoint
+{
+
+ public String echo(final String message);
+
+}
Added:
shared-testsuite/trunk/testsuite/src/test/java/org/jboss/test/ws/jaxws/jbws3401/TestEndpointImpl.java
===================================================================
---
shared-testsuite/trunk/testsuite/src/test/java/org/jboss/test/ws/jaxws/jbws3401/TestEndpointImpl.java
(rev 0)
+++
shared-testsuite/trunk/testsuite/src/test/java/org/jboss/test/ws/jaxws/jbws3401/TestEndpointImpl.java 2011-12-16
10:21:17 UTC (rev 15402)
@@ -0,0 +1,40 @@
+/*
+* JBoss, Home of Professional Open Source.
+* Copyright 2011, 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.jbws3401;
+
+import javax.ejb.Stateless;
+import javax.jws.WebService;
+
+/**
+ * @author <a href="mailto:ropalka@redhat.com">Richard Opalka</a>
+ */
+@WebService(name = "TestEndpoint", serviceName="TestEndpointService",
targetNamespace = "http://org.jboss.test.ws/jbws3401",
wsdlLocation="WEB-INF/wsdl/TestService.wsdl")
+@Stateless
+public class TestEndpointImpl implements TestEndpoint
+{
+
+ public String echo(String message)
+ {
+ return message;
+ }
+
+}
Added:
shared-testsuite/trunk/testsuite/src/test/resources/jaxws/jbws3401/WEB-INF/wsdl/TestService.wsdl
===================================================================
---
shared-testsuite/trunk/testsuite/src/test/resources/jaxws/jbws3401/WEB-INF/wsdl/TestService.wsdl
(rev 0)
+++
shared-testsuite/trunk/testsuite/src/test/resources/jaxws/jbws3401/WEB-INF/wsdl/TestService.wsdl 2011-12-16
10:21:17 UTC (rev 15402)
@@ -0,0 +1,51 @@
+<definitions name='TestEndpointService'
targetNamespace='http://org.jboss.test.ws/jbws3401'
xmlns='http://schemas.xmlsoap.org/wsdl/'
xmlns:soap='http://schemas.xmlsoap.org/wsdl/soap/'
xmlns:tns='http://org.jboss.test.ws/jbws3401'
xmlns:xsd='http://www.w3.org/2001/XMLSchema'>
+ <types>
+ <xs:schema targetNamespace='http://org.jboss.test.ws/jbws3401'
version='1.0' xmlns:tns='http://org.jboss.test.ws/jbws3401'
xmlns:xs='http://www.w3.org/2001/XMLSchema'>
+
+ <xs:import namespace="http://org.jboss.test.ws/jbws3401/schema1"
schemaLocation="./schema1.xsd"/>
+ <xs:import namespace="http://org.jboss.test.ws/jbws3401/schema4"
schemaLocation="./schema4.xsd"/>
+
+ <xs:element name='echo' type='tns:echo'/>
+ <xs:element name='echoResponse' type='tns:echoResponse'/>
+ <xs:complexType name='echo'>
+ <xs:sequence>
+ <xs:element minOccurs='0' name='arg0'
type='xs:string'/>
+ </xs:sequence>
+ </xs:complexType>
+ <xs:complexType name='echoResponse'>
+ <xs:sequence>
+ <xs:element minOccurs='0' name='return'
type='xs:string'/>
+ </xs:sequence>
+ </xs:complexType>
+ </xs:schema>
+ </types>
+ <message name='TestEndpoint_echoResponse'>
+ <part element='tns:echoResponse'
name='echoResponse'></part>
+ </message>
+ <message name='TestEndpoint_echo'>
+ <part element='tns:echo' name='echo'></part>
+ </message>
+ <portType name='TestEndpoint'>
+ <operation name='echo' parameterOrder='echo'>
+ <input message='tns:TestEndpoint_echo'></input>
+ <output message='tns:TestEndpoint_echoResponse'></output>
+ </operation>
+ </portType>
+ <binding name='TestEndpointBinding' type='tns:TestEndpoint'>
+ <soap:binding style='document'
transport='http://schemas.xmlsoap.org/soap/http'/>
+ <operation name='echo'>
+ <soap:operation soapAction=''/>
+ <input>
+ <soap:body use='literal'/>
+ </input>
+ <output>
+ <soap:body use='literal'/>
+ </output>
+ </operation>
+ </binding>
+ <service name='TestEndpointService'>
+ <port binding='tns:TestEndpointBinding' name='TestEndpointPort'>
+ <soap:address location='http://127.0.0.1:8080/jaxws-jbws3401'/>
+ </port>
+ </service>
+</definitions>
\ No newline at end of file
Added:
shared-testsuite/trunk/testsuite/src/test/resources/jaxws/jbws3401/WEB-INF/wsdl/schema1.xsd
===================================================================
---
shared-testsuite/trunk/testsuite/src/test/resources/jaxws/jbws3401/WEB-INF/wsdl/schema1.xsd
(rev 0)
+++
shared-testsuite/trunk/testsuite/src/test/resources/jaxws/jbws3401/WEB-INF/wsdl/schema1.xsd 2011-12-16
10:21:17 UTC (rev 15402)
@@ -0,0 +1,5 @@
+<schema targetNamespace='http://org.jboss.test.ws/jbws3401/schema1'
+
xmlns='http://www.w3.org/2001/XMLSchema'>
+ <import namespace="http://org.jboss.test.ws/jbws3401/schema2"
schemaLocation="./schema2.xsd"/>
+ <import namespace="http://org.jboss.test.ws/jbws3401/schema5"
schemaLocation="./schema5.xsd"/>
+</schema>
\ No newline at end of file
Added:
shared-testsuite/trunk/testsuite/src/test/resources/jaxws/jbws3401/WEB-INF/wsdl/schema2.xsd
===================================================================
---
shared-testsuite/trunk/testsuite/src/test/resources/jaxws/jbws3401/WEB-INF/wsdl/schema2.xsd
(rev 0)
+++
shared-testsuite/trunk/testsuite/src/test/resources/jaxws/jbws3401/WEB-INF/wsdl/schema2.xsd 2011-12-16
10:21:17 UTC (rev 15402)
@@ -0,0 +1,4 @@
+<schema targetNamespace='http://org.jboss.test.ws/jbws3401/schema2'
+
xmlns='http://www.w3.org/2001/XMLSchema'>
+
+</schema>
\ No newline at end of file
Added:
shared-testsuite/trunk/testsuite/src/test/resources/jaxws/jbws3401/WEB-INF/wsdl/schema3.xsd
===================================================================
---
shared-testsuite/trunk/testsuite/src/test/resources/jaxws/jbws3401/WEB-INF/wsdl/schema3.xsd
(rev 0)
+++
shared-testsuite/trunk/testsuite/src/test/resources/jaxws/jbws3401/WEB-INF/wsdl/schema3.xsd 2011-12-16
10:21:17 UTC (rev 15402)
@@ -0,0 +1,4 @@
+<schema targetNamespace='http://org.jboss.test.ws/jbws3401/schema3'
+
xmlns='http://www.w3.org/2001/XMLSchema'>
+
+</schema>
\ No newline at end of file
Added:
shared-testsuite/trunk/testsuite/src/test/resources/jaxws/jbws3401/WEB-INF/wsdl/schema4.xsd
===================================================================
---
shared-testsuite/trunk/testsuite/src/test/resources/jaxws/jbws3401/WEB-INF/wsdl/schema4.xsd
(rev 0)
+++
shared-testsuite/trunk/testsuite/src/test/resources/jaxws/jbws3401/WEB-INF/wsdl/schema4.xsd 2011-12-16
10:21:17 UTC (rev 15402)
@@ -0,0 +1,5 @@
+<schema targetNamespace='http://org.jboss.test.ws/jbws3401/schema4'
+
xmlns='http://www.w3.org/2001/XMLSchema'>
+ <import namespace="http://org.jboss.test.ws/jbws3401/schema2"
schemaLocation="./schema2.xsd"/>
+ <import namespace="http://org.jboss.test.ws/jbws3401/schema3"
schemaLocation="./schema3.xsd"/>
+</schema>
\ No newline at end of file
Added:
shared-testsuite/trunk/testsuite/src/test/resources/jaxws/jbws3401/WEB-INF/wsdl/schema5.xsd
===================================================================
---
shared-testsuite/trunk/testsuite/src/test/resources/jaxws/jbws3401/WEB-INF/wsdl/schema5.xsd
(rev 0)
+++
shared-testsuite/trunk/testsuite/src/test/resources/jaxws/jbws3401/WEB-INF/wsdl/schema5.xsd 2011-12-16
10:21:17 UTC (rev 15402)
@@ -0,0 +1,4 @@
+<schema targetNamespace='http://org.jboss.test.ws/jbws3401/schema5'
+
xmlns='http://www.w3.org/2001/XMLSchema'>
+
+</schema>
\ No newline at end of file