Author: alessio.soldano(a)jboss.com
Date: 2008-07-02 10:51:23 -0400 (Wed, 02 Jul 2008)
New Revision: 7766
Added:
framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/jbws1841/EndpointService.java
framework/trunk/testsuite/test/resources/jaxws/jbws1841/META-INF_4/
framework/trunk/testsuite/test/resources/jaxws/jbws1841/META-INF_4/ejb-jar.xml
framework/trunk/testsuite/test/resources/jaxws/jbws1841/META-INF_4/jboss.xml
framework/trunk/testsuite/test/resources/jaxws/jbws1841/META-INF_4/wsdl/
framework/trunk/testsuite/test/resources/jaxws/jbws1841/META-INF_4/wsdl/TestService.wsdl
Modified:
framework/trunk/testsuite/test/ant-import/build-jars-jaxws.xml
framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/jbws1841/JBWS1841TestCase.java
framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/jbws1841/StatelessBean.java
framework/trunk/testsuite/test/resources/jaxws/jbws1841/META-INF/ejb-jar.xml
framework/trunk/testsuite/test/resources/jaxws/jbws1841/META-INF/jboss.xml
Log:
[JBWS-2130] Fixing jbws1841 test too
Modified: framework/trunk/testsuite/test/ant-import/build-jars-jaxws.xml
===================================================================
--- framework/trunk/testsuite/test/ant-import/build-jars-jaxws.xml 2008-07-02 14:46:29 UTC
(rev 7765)
+++ framework/trunk/testsuite/test/ant-import/build-jars-jaxws.xml 2008-07-02 14:51:23 UTC
(rev 7766)
@@ -424,7 +424,19 @@
<jar destfile="${tests.output.dir}/test-libs/jaxws-jbws1841.jar">
<fileset dir="${tests.output.dir}/test-classes">
<include name="org/jboss/test/ws/jaxws/jbws1841/*.class"/>
+ <exclude
name="org/jboss/test/ws/jaxws/jbws1841/*TestCase.class"/>
</fileset>
+ <metainf
dir="${tests.output.dir}/test-resources/jaxws/jbws1841/META-INF_4">
+ <include name="wsdl/*"/>
+ <include name="ejb-jar.xml"/>
+ <include name="jboss.xml"/>
+ </metainf>
+ </jar>
+ <jar destfile="${tests.output.dir}/test-libs/jaxws-jbws1841-as5.jar">
+ <fileset dir="${tests.output.dir}/test-classes">
+ <include name="org/jboss/test/ws/jaxws/jbws1841/*.class"/>
+ <exclude
name="org/jboss/test/ws/jaxws/jbws1841/*TestCase.class"/>
+ </fileset>
<metainf
dir="${tests.output.dir}/test-resources/jaxws/jbws1841/META-INF">
<include name="wsdl/*"/>
<include name="ejb-jar.xml"/>
Added:
framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/jbws1841/EndpointService.java
===================================================================
---
framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/jbws1841/EndpointService.java
(rev 0)
+++
framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/jbws1841/EndpointService.java 2008-07-02
14:51:23 UTC (rev 7766)
@@ -0,0 +1,43 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.jbws1841;
+
+import java.net.URL;
+
+import javax.xml.namespace.QName;
+import javax.xml.ws.WebEndpoint;
+import javax.xml.ws.WebServiceClient;
+
+@WebServiceClient(name="EndpointService",
targetNamespace="http://www.openuri.org/2004/04/HelloWorld")
+public class EndpointService extends javax.xml.ws.Service
+{
+ private final static QName TESTENDPOINTPORT = new
QName("http://www.openuri.org/2004/04/HelloWorld",
"EndpointInterfacePort");
+
+ public EndpointService(URL wsdlLocation, QName serviceName) {
+ super(wsdlLocation, serviceName);
+ }
+
+ @WebEndpoint(name = "EndpointInterfacePort")
+ public EndpointInterface getEndpointPort() {
+ return (EndpointInterface)super.getPort(TESTENDPOINTPORT,
EndpointInterface.class);
+ }
+}
Property changes on:
framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/jbws1841/EndpointService.java
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Modified:
framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/jbws1841/JBWS1841TestCase.java
===================================================================
---
framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/jbws1841/JBWS1841TestCase.java 2008-07-02
14:46:29 UTC (rev 7765)
+++
framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/jbws1841/JBWS1841TestCase.java 2008-07-02
14:51:23 UTC (rev 7766)
@@ -2,6 +2,7 @@
import junit.framework.Test;
import org.jboss.wsf.test.JBossWSTest;
+import org.jboss.wsf.test.JBossWSTestHelper;
import org.jboss.wsf.test.JBossWSTestSetup;
import javax.xml.namespace.QName;
@@ -26,7 +27,8 @@
public static Test suite()
{
- return new JBossWSTestSetup(JBWS1841TestCase.class,
"jaxws-jbws1841.jar");
+ //here in the AS 5 jar we use <service-qname> that does not exist in AS
4.2.x
+ return new JBossWSTestSetup(JBWS1841TestCase.class, new
JBossWSTestHelper().isTargetJBoss50() ? "jaxws-jbws1841-as5.jar" :
"jaxws-jbws1841.jar");
}
protected void setUp() throws Exception
Modified:
framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/jbws1841/StatelessBean.java
===================================================================
---
framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/jbws1841/StatelessBean.java 2008-07-02
14:46:29 UTC (rev 7765)
+++
framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/jbws1841/StatelessBean.java 2008-07-02
14:51:23 UTC (rev 7766)
@@ -31,6 +31,7 @@
* A test bean that delegates to a web service provided through serviceref injection.
*
* @author <a href="mailto:bdecoste@jboss.com">William DeCoste</a>
+ * @author alessio.soldano(a)jboss.com
* @version $Revision$
*/
@Stateless(name="StatelessBean")
@@ -39,12 +40,12 @@
{
private static final Logger log = Logger.getLogger(StatelessBean.class);
- @WebServiceRef(mappedName="jbossws-client/service/TestService",
wsdlLocation="META-INF/wsdl/TestService.wsdl")
+ @WebServiceRef(value = EndpointService.class,
mappedName="jbossws-client/service/TestService",
wsdlLocation="META-INF/wsdl/TestService.wsdl")
EndpointInterface endpoint1;
EndpointInterface endpoint2;
- @WebServiceRef(mappedName="jbossws-client/service/TestService",
wsdlLocation="META-INF/wsdl/TestService.wsdl")
+ @WebServiceRef(value = EndpointService.class,
mappedName="jbossws-client/service/TestService",
wsdlLocation="META-INF/wsdl/TestService.wsdl")
public void setEndpoint2(EndpointInterface endpoint2)
{
this.endpoint2 = endpoint2;
Modified: framework/trunk/testsuite/test/resources/jaxws/jbws1841/META-INF/ejb-jar.xml
===================================================================
---
framework/trunk/testsuite/test/resources/jaxws/jbws1841/META-INF/ejb-jar.xml 2008-07-02
14:46:29 UTC (rev 7765)
+++
framework/trunk/testsuite/test/resources/jaxws/jbws1841/META-INF/ejb-jar.xml 2008-07-02
14:51:23 UTC (rev 7766)
@@ -11,7 +11,7 @@
<ejb-name>StatelessBean</ejb-name>
<service-ref>
<service-ref-name>service/Endpoint3</service-ref-name>
- <service-interface>javax.xml.ws.Service</service-interface>
+
<service-interface>org.jboss.test.ws.jaxws.jbws1841.EndpointService</service-interface>
<mapped-name>jbossws-client/service/TestService</mapped-name>
<injection-target>
<injection-target-class>org.jboss.test.ws.jaxws.jbws1841.StatelessBean</injection-target-class>
Modified: framework/trunk/testsuite/test/resources/jaxws/jbws1841/META-INF/jboss.xml
===================================================================
--- framework/trunk/testsuite/test/resources/jaxws/jbws1841/META-INF/jboss.xml 2008-07-02
14:46:29 UTC (rev 7765)
+++ framework/trunk/testsuite/test/resources/jaxws/jbws1841/META-INF/jboss.xml 2008-07-02
14:51:23 UTC (rev 7766)
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8"?>
-<!DOCTYPE jboss PUBLIC "-//JBoss//DTD JBOSS 4.0//EN"
"http://www.jboss.org/j2ee/dtd/jboss_4_0.dtd">
+<!DOCTYPE jboss PUBLIC "-//JBoss//DTD JBOSS 5.0//EN"
"http://www.jboss.org/j2ee/dtd/jboss_5_0.dtd">
<jboss>
@@ -12,6 +12,8 @@
</service-ref>
<service-ref>
<service-ref-name>service/Endpoint4</service-ref-name>
+ <!-- Metro compatibility: we declare the service-qname since we're
using javax.xml.ws.Service in the ejb-jar.xml -->
+
<
service-qname>{http://www.openuri.org/2004/04/HelloWorld}EndpointServi...
<wsdl-override>META-INF/wsdl/TestService.wsdl</wsdl-override>
</service-ref>
</session>
Added: framework/trunk/testsuite/test/resources/jaxws/jbws1841/META-INF_4/ejb-jar.xml
===================================================================
--- framework/trunk/testsuite/test/resources/jaxws/jbws1841/META-INF_4/ejb-jar.xml
(rev 0)
+++
framework/trunk/testsuite/test/resources/jaxws/jbws1841/META-INF_4/ejb-jar.xml 2008-07-02
14:51:23 UTC (rev 7766)
@@ -0,0 +1,32 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<ejb-jar version="3.0"
+
xmlns="http://java.sun.com/xml/ns/javaee"
+
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+
xsi:schemaLocation="http://java.sun.com/xml/ns/javaee
http://java.sun.com/xml/ns/javaee/ejb-jar_3_0.xsd">
+
+ <description>jBoss test application</description>
+ <display-name>Test</display-name>
+ <enterprise-beans>
+ <session>
+ <ejb-name>StatelessBean</ejb-name>
+ <service-ref>
+ <service-ref-name>service/Endpoint3</service-ref-name>
+
<service-interface>org.jboss.test.ws.jaxws.jbws1841.EndpointService</service-interface>
+ <mapped-name>jbossws-client/service/TestService</mapped-name>
+ <injection-target>
+
<injection-target-class>org.jboss.test.ws.jaxws.jbws1841.StatelessBean</injection-target-class>
+ <injection-target-name>endpoint3</injection-target-name>
+ </injection-target>
+ </service-ref>
+ <service-ref>
+ <service-ref-name>service/Endpoint4</service-ref-name>
+
<service-interface>org.jboss.test.ws.jaxws.jbws1841.EndpointService</service-interface>
+ <mapped-name>jbossws-client/service/TestService</mapped-name>
+ <injection-target>
+
<injection-target-class>org.jboss.test.ws.jaxws.jbws1841.StatelessBean</injection-target-class>
+ <injection-target-name>setEndpoint4</injection-target-name>
+ </injection-target>
+ </service-ref>
+ </session>
+ </enterprise-beans>
+</ejb-jar>
Property changes on:
framework/trunk/testsuite/test/resources/jaxws/jbws1841/META-INF_4/ejb-jar.xml
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Added: framework/trunk/testsuite/test/resources/jaxws/jbws1841/META-INF_4/jboss.xml
===================================================================
--- framework/trunk/testsuite/test/resources/jaxws/jbws1841/META-INF_4/jboss.xml
(rev 0)
+++
framework/trunk/testsuite/test/resources/jaxws/jbws1841/META-INF_4/jboss.xml 2008-07-02
14:51:23 UTC (rev 7766)
@@ -0,0 +1,19 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE jboss PUBLIC "-//JBoss//DTD JBOSS 4.0//EN"
"http://www.jboss.org/j2ee/dtd/jboss_4_0.dtd">
+
+<jboss>
+
+ <enterprise-beans>
+ <session>
+ <ejb-name>StatelessBean</ejb-name>
+ <service-ref>
+ <service-ref-name>service/Endpoint3</service-ref-name>
+ <wsdl-override>META-INF/wsdl/TestService.wsdl</wsdl-override>
+ </service-ref>
+ <service-ref>
+ <service-ref-name>service/Endpoint4</service-ref-name>
+ <wsdl-override>META-INF/wsdl/TestService.wsdl</wsdl-override>
+ </service-ref>
+ </session>
+ </enterprise-beans>
+</jboss>
\ No newline at end of file
Property changes on:
framework/trunk/testsuite/test/resources/jaxws/jbws1841/META-INF_4/jboss.xml
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Added:
framework/trunk/testsuite/test/resources/jaxws/jbws1841/META-INF_4/wsdl/TestService.wsdl
===================================================================
---
framework/trunk/testsuite/test/resources/jaxws/jbws1841/META-INF_4/wsdl/TestService.wsdl
(rev 0)
+++
framework/trunk/testsuite/test/resources/jaxws/jbws1841/META-INF_4/wsdl/TestService.wsdl 2008-07-02
14:51:23 UTC (rev 7766)
@@ -0,0 +1,39 @@
+<definitions name='EndpointService'
targetNamespace='http://www.openuri.org/2004/04/HelloWorld'
+
xmlns='http://schemas.xmlsoap.org/wsdl/'
+
xmlns:soap='http://schemas.xmlsoap.org/wsdl/soap/'
+
xmlns:tns='http://www.openuri.org/2004/04/HelloWorld'
+
xmlns:xsd='http://www.w3.org/2001/XMLSchema'>
+ <types></types>
+ <message name='EndpointInterface_echoResponse'>
+ <part name='return' type='xsd:string'></part>
+ </message>
+ <message name='EndpointInterface_echo'>
+ <part name='arg0' type='xsd:string'></part>
+ </message>
+ <portType name='EndpointInterface'>
+
+ <operation name='echo' parameterOrder='arg0'>
+ <input message='tns:EndpointInterface_echo'></input>
+ <output
message='tns:EndpointInterface_echoResponse'></output>
+ </operation>
+ </portType>
+ <binding name='EndpointInterfaceBinding'
type='tns:EndpointInterface'>
+ <soap:binding style='rpc'
transport='http://schemas.xmlsoap.org/soap/http'/>
+ <operation name='echo'>
+ <soap:operation soapAction=''/>
+
+ <input>
+ <soap:body
namespace='http://www.openuri.org/2004/04/HelloWorld'
use='literal'/>
+ </input>
+ <output>
+ <soap:body
namespace='http://www.openuri.org/2004/04/HelloWorld'
use='literal'/>
+ </output>
+ </operation>
+ </binding>
+ <service name='EndpointService'>
+
+ <port binding='tns:EndpointInterfaceBinding'
name='EndpointInterfacePort'>
+ <soap:address
location='http://@jboss.bind.address@:8080/jaxws-jbws1841/EJB3Bean'/>
+ </port>
+ </service>
+</definitions>
\ No newline at end of file
Property changes on:
framework/trunk/testsuite/test/resources/jaxws/jbws1841/META-INF_4/wsdl/TestService.wsdl
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF