Author: richard.opalka(a)jboss.com
Date: 2009-02-07 07:12:19 -0500 (Sat, 07 Feb 2009)
New Revision: 9257
Added:
framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/jbws2307/
framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/jbws2307/ClientServlet.java
framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/jbws2307/Hello.java
framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/jbws2307/HelloImpl.java
framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/jbws2307/HelloService.java
framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/jbws2307/JBWS2307TestCase.java
framework/trunk/testsuite/test/resources/jaxws/jbws2307/
framework/trunk/testsuite/test/resources/jaxws/jbws2307/WEB-INF-client/
framework/trunk/testsuite/test/resources/jaxws/jbws2307/WEB-INF-client/jboss-web.xml
framework/trunk/testsuite/test/resources/jaxws/jbws2307/WEB-INF-client/web.xml
framework/trunk/testsuite/test/resources/jaxws/jbws2307/WEB-INF-client/wsdl/
framework/trunk/testsuite/test/resources/jaxws/jbws2307/WEB-INF-client/wsdl/HelloService.wsdl
framework/trunk/testsuite/test/resources/jaxws/jbws2307/WEB-INF-service/
framework/trunk/testsuite/test/resources/jaxws/jbws2307/WEB-INF-service/jboss-web.xml
framework/trunk/testsuite/test/resources/jaxws/jbws2307/WEB-INF-service/web.xml
framework/trunk/testsuite/test/resources/jaxws/jbws2307/WEB-INF-service/wsdl/
framework/trunk/testsuite/test/resources/jaxws/jbws2307/WEB-INF-service/wsdl/HelloService.wsdl
Modified:
framework/trunk/testsuite/test/ant-import/build-jars-jaxws.xml
Log:
[JBWS-2307] refactoring test to framework
Modified: framework/trunk/testsuite/test/ant-import/build-jars-jaxws.xml
===================================================================
--- framework/trunk/testsuite/test/ant-import/build-jars-jaxws.xml 2009-02-07 12:11:14 UTC
(rev 9256)
+++ framework/trunk/testsuite/test/ant-import/build-jars-jaxws.xml 2009-02-07 12:12:19 UTC
(rev 9257)
@@ -605,6 +605,30 @@
</webinf>
</war>
+ <!-- jbws2307 -->
+ <war warfile="${tests.output.dir}/test-libs/jaxws-jbws2307-client.war"
webxml="${tests.output.dir}/test-resources/jaxws/jbws2307/WEB-INF-client/web.xml">
+ <classes dir="${tests.output.dir}/test-classes">
+ <include
name="org/jboss/test/ws/jaxws/jbws2307/ClientServlet.class"/>
+ <include name="org/jboss/test/ws/jaxws/jbws2307/Hello.class"/>
+ <include
name="org/jboss/test/ws/jaxws/jbws2307/HelloService.class"/>
+ </classes>
+ <webinf
dir="${tests.output.dir}/test-resources/jaxws/jbws2307/WEB-INF-client">
+ <include name="wsdl/**"/>
+ <include name="*.xml"/>
+ </webinf>
+ </war>
+ <war warfile="${tests.output.dir}/test-libs/jaxws-jbws2307-service.war"
webxml="${tests.output.dir}/test-resources/jaxws/jbws2307/WEB-INF-service/web.xml">
+ <classes dir="${tests.output.dir}/test-classes">
+ <include name="org/jboss/test/ws/jaxws/jbws2307/Hello.class"/>
+ <include
name="org/jboss/test/ws/jaxws/jbws2307/HelloImpl.class"/>
+ <include
name="org/jboss/test/ws/jaxws/jbws2307/HelloService.class"/>
+ </classes>
+ <webinf
dir="${tests.output.dir}/test-resources/jaxws/jbws2307/WEB-INF-service">
+ <include name="wsdl/**"/>
+ <include name="*.xml"/>
+ </webinf>
+ </war>
+
<!-- jaxws-jbws2412 -->
<war warfile="${tests.output.dir}/test-libs/jaxws-jbws2412.war"
webxml="${tests.output.dir}/test-resources/jaxws/jbws2412/WEB-INF/web.xml">
<classes dir="${tests.output.dir}/test-classes">
Added:
framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/jbws2307/ClientServlet.java
===================================================================
---
framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/jbws2307/ClientServlet.java
(rev 0)
+++
framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/jbws2307/ClientServlet.java 2009-02-07
12:12:19 UTC (rev 9257)
@@ -0,0 +1,64 @@
+/*
+ * 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.jbws2307;
+
+import java.io.IOException;
+
+import javax.servlet.ServletException;
+import javax.servlet.http.HttpServlet;
+import javax.servlet.http.HttpServletRequest;
+import javax.servlet.http.HttpServletResponse;
+import javax.xml.ws.WebServiceRef;
+
+import org.jboss.logging.Logger;
+
+/**
+ * Client servlet using the injected service
+ *
+ * @author alessio.soldano(a)jboss.com
+ */
+public class ClientServlet extends HttpServlet
+{
+ private Logger log = Logger.getLogger(ClientServlet.class);
+
+ @WebServiceRef(name="service/jbws2307service")
+ HelloService service;
+
+ protected void doGet(HttpServletRequest req, HttpServletResponse resp) throws
ServletException, IOException
+ {
+ boolean result = false;
+ try
+ {
+ log.info("service = "+service);
+ Hello hello = service.getHelloPort();
+ result = hello.getMessageContextTest();
+ log.info("result = " + result);
+ }
+ catch (Exception e)
+ {
+ log.error("Error while invoking service!", e);
+ throw new ServletException(e);
+ }
+ resp.getWriter().print(result);
+ }
+
+}
Added: framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/jbws2307/Hello.java
===================================================================
--- framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/jbws2307/Hello.java
(rev 0)
+++
framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/jbws2307/Hello.java 2009-02-07
12:12:19 UTC (rev 9257)
@@ -0,0 +1,53 @@
+/*
+ * 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.jbws2307;
+
+import javax.jws.WebMethod;
+import javax.jws.WebParam;
+import javax.jws.WebResult;
+import javax.jws.WebService;
+import javax.jws.soap.SOAPBinding;
+
+@WebService(name="Hello",
targetNamespace="http://helloservice.org/wsdl")
+(a)SOAPBinding(style=SOAPBinding.Style.RPC)
+public abstract interface Hello
+{
+ @WebMethod
+ @WebResult(name="result", partName="result")
+ public abstract String hello(@WebParam(name="String_1",
partName="String_1") String paramString);
+
+ @WebMethod
+ @WebResult(name="result", partName="result")
+ public abstract boolean getMessageContextTest();
+
+ @WebMethod
+ @WebResult(name="result", partName="result")
+ public abstract boolean getServletContextTest();
+
+ @WebMethod
+ @WebResult(name="result", partName="result")
+ public abstract boolean getUserPrincipalTest();
+
+ @WebMethod
+ @WebResult(name="result", partName="result")
+ public abstract boolean isUserInRoleTest(@WebParam(name="String_1",
partName="String_1") String paramString);
+}
\ No newline at end of file
Added:
framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/jbws2307/HelloImpl.java
===================================================================
--- framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/jbws2307/HelloImpl.java
(rev 0)
+++
framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/jbws2307/HelloImpl.java 2009-02-07
12:12:19 UTC (rev 9257)
@@ -0,0 +1,80 @@
+/*
+ * 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.jbws2307;
+
+import java.security.Principal;
+import javax.annotation.Resource;
+import javax.jws.WebService;
+import javax.servlet.ServletContext;
+import javax.xml.ws.WebServiceContext;
+import javax.xml.ws.handler.MessageContext;
+
+@WebService(portName = "HelloPort", serviceName = "HelloService",
targetNamespace = "http://helloservice.org/wsdl", wsdlLocation =
"WEB-INF/wsdl/HelloService.wsdl", endpointInterface =
"org.jboss.test.ws.jaxws.jbws2307.Hello")
+public class HelloImpl implements Hello
+{
+
+ @Resource
+ protected WebServiceContext wsContext;
+
+ public String hello(String s)
+ {
+ return "Hello, " + s + "!";
+ }
+
+ public boolean getServletContextTest()
+ {
+ if (this.wsContext == null)
+ return false;
+
+ ServletContext v =
(ServletContext)this.wsContext.getMessageContext().get("javax.xml.ws.servlet.context");
+ System.out.println("ServletContext=" + v);
+ return true;
+ }
+
+ public boolean getMessageContextTest()
+ {
+ if (this.wsContext == null)
+ return false;
+
+ MessageContext v = this.wsContext.getMessageContext();
+ System.out.println("MessageContext=" + v);
+ return true;
+ }
+
+ public boolean getUserPrincipalTest()
+ {
+ if (this.wsContext == null)
+ return false;
+
+ Principal v = this.wsContext.getUserPrincipal();
+ System.out.println("UserPrincipal=" + v);
+ return true;
+ }
+
+ public boolean isUserInRoleTest(String s)
+ {
+ if (this.wsContext == null)
+ return false;
+
+ return this.wsContext.isUserInRole(s);
+ }
+}
Added:
framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/jbws2307/HelloService.java
===================================================================
---
framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/jbws2307/HelloService.java
(rev 0)
+++
framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/jbws2307/HelloService.java 2009-02-07
12:12:19 UTC (rev 9257)
@@ -0,0 +1,65 @@
+/*
+ * 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.jbws2307;
+
+import java.net.URL;
+
+import javax.xml.namespace.QName;
+import javax.xml.ws.Service;
+import javax.xml.ws.WebEndpoint;
+import javax.xml.ws.WebServiceClient;
+
+@WebServiceClient(name = "HelloService", targetNamespace =
"http://helloservice.org/wsdl", wsdlLocation =
"WEB-INF/wsdl/HelloService.wsdl")
+public class HelloService extends Service
+{
+ private static final URL HELLOSERVICE_WSDL_LOCATION;
+
+ public HelloService(URL wsdlLocation, QName serviceName)
+ {
+ super(wsdlLocation, serviceName);
+ }
+
+ public HelloService()
+ {
+ super(HELLOSERVICE_WSDL_LOCATION, new
QName("http://helloservice.org/wsdl", "HelloService"));
+ }
+
+ @WebEndpoint(name = "HelloPort")
+ public Hello getHelloPort()
+ {
+ return ((Hello)super.getPort(new
QName("http://helloservice.org/wsdl",
"HelloPort"), Hello.class));
+ }
+
+ static
+ {
+ URL url = null;
+ try
+ {
+ url = new
URL("http://files1/releng/cts_5.x/cts-5.0c-temp/bin/WEB-INF/wsdl/HelloService.wsdl");
+ }
+ catch (Exception e)
+ {
+ e.printStackTrace();
+ }
+ HELLOSERVICE_WSDL_LOCATION = url;
+ }
+}
Added:
framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/jbws2307/JBWS2307TestCase.java
===================================================================
---
framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/jbws2307/JBWS2307TestCase.java
(rev 0)
+++
framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/jbws2307/JBWS2307TestCase.java 2009-02-07
12:12:19 UTC (rev 9257)
@@ -0,0 +1,52 @@
+/*
+ * 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.jbws2307;
+
+import java.io.BufferedReader;
+import java.io.InputStreamReader;
+import java.net.HttpURLConnection;
+import java.net.URL;
+
+import junit.framework.Test;
+
+import org.jboss.wsf.test.JBossWSTest;
+import org.jboss.wsf.test.JBossWSTestSetup;
+
+/**
+ * JBWS-2307 testcase
+ *
+ * @author alessio.soldano(a)jboss.com
+ */
+public class JBWS2307TestCase extends JBossWSTest
+{
+ public static Test suite()
+ {
+ return new JBossWSTestSetup(JBWS2307TestCase.class,
"jaxws-jbws2307-client.war, jaxws-jbws2307-service.war");
+ }
+
+ public void testClient() throws Exception
+ {
+ HttpURLConnection con = (HttpURLConnection)new URL("http://" +
getServerHost() + ":8080/jaxws-jbws2307-client/jbws2307").openConnection();
+ BufferedReader isr = new BufferedReader(new
InputStreamReader(con.getInputStream()));
+ assertEquals("true", isr.readLine());
+ }
+}
Added:
framework/trunk/testsuite/test/resources/jaxws/jbws2307/WEB-INF-client/jboss-web.xml
===================================================================
--- framework/trunk/testsuite/test/resources/jaxws/jbws2307/WEB-INF-client/jboss-web.xml
(rev 0)
+++
framework/trunk/testsuite/test/resources/jaxws/jbws2307/WEB-INF-client/jboss-web.xml 2009-02-07
12:12:19 UTC (rev 9257)
@@ -0,0 +1,21 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE jboss-web PUBLIC "-//JBoss//DTD Web Application 5.0//EN"
"http://www.jboss.org/j2ee/dtd/jboss-web_5_0.dtd">
+
+<jboss-web>
+ <security-domain>java:/jaas/JBossWS</security-domain>
+ <service-ref>
+ <service-ref-name>service/jbws2307service</service-ref-name>
+ <port-component-ref>
+
<service-endpoint-interface>org.jboss.test.ws.jaxws.jbws2307.Hello</service-endpoint-interface>
+ <
port-qname>{http://helloservice.org/wsdl}HelloPort</port-qname>
+ <stub-property>
+ <prop-name>javax.xml.ws.security.auth.password</prop-name>
+ <prop-value>thefrog</prop-value>
+ </stub-property>
+ <stub-property>
+ <prop-name>javax.xml.ws.security.auth.username</prop-name>
+ <prop-value>kermit</prop-value>
+ </stub-property>
+ </port-component-ref>
+ </service-ref>
+</jboss-web>
\ No newline at end of file
Added: framework/trunk/testsuite/test/resources/jaxws/jbws2307/WEB-INF-client/web.xml
===================================================================
--- framework/trunk/testsuite/test/resources/jaxws/jbws2307/WEB-INF-client/web.xml
(rev 0)
+++
framework/trunk/testsuite/test/resources/jaxws/jbws2307/WEB-INF-client/web.xml 2009-02-07
12:12:19 UTC (rev 9257)
@@ -0,0 +1,23 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<web-app version="2.5"
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/web-app_2_5.xsd">
+ <display-name>jbws2307_testcase_client</display-name>
+ <servlet>
+ <servlet-name>ClientServlet</servlet-name>
+
<servlet-class>org.jboss.test.ws.jaxws.jbws2307.ClientServlet</servlet-class>
+ </servlet>
+ <servlet-mapping>
+ <servlet-name>ClientServlet</servlet-name>
+ <url-pattern>/jbws2307</url-pattern>
+ </servlet-mapping>
+ <session-config>
+ <session-timeout>54</session-timeout>
+ </session-config>
+ <service-ref>
+ <service-ref-name>service/jbws2307service</service-ref-name>
+ <service-interface>javax.xml.ws.Service</service-interface>
+ <wsdl-file>WEB-INF/wsdl/HelloService.wsdl</wsdl-file>
+ <port-component-ref>
+
<service-endpoint-interface>org.jboss.test.ws.jaxws.jbws2307.Hello</service-endpoint-interface>
+ </port-component-ref>
+ </service-ref>
+</web-app>
\ No newline at end of file
Added:
framework/trunk/testsuite/test/resources/jaxws/jbws2307/WEB-INF-client/wsdl/HelloService.wsdl
===================================================================
---
framework/trunk/testsuite/test/resources/jaxws/jbws2307/WEB-INF-client/wsdl/HelloService.wsdl
(rev 0)
+++
framework/trunk/testsuite/test/resources/jaxws/jbws2307/WEB-INF-client/wsdl/HelloService.wsdl 2009-02-07
12:12:19 UTC (rev 9257)
@@ -0,0 +1,74 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<definitions name="HelloService"
targetNamespace="http://helloservice.org/wsdl"
xmlns:tns="http://helloservice.org/wsdl"
xmlns="http://schemas.xmlsoap.org/wsdl/"
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/">
+ <types/>
+ <message name="Hello_hello">
+ <part name="String_1" type="xsd:string"/></message>
+ <message name="Hello_helloResponse">
+ <part name="result" type="xsd:string"/></message>
+ <message name="getMessageContextTest"/>
+ <message name="getMessageContextTestResponse">
+ <part name="result" type="xsd:boolean"/></message>
+ <message name="getServletContextTest"/>
+ <message name="getServletContextTestResponse">
+ <part name="result" type="xsd:boolean"/></message>
+ <message name="getUserPrincipalTest"/>
+ <message name="getUserPrincipalTestResponse">
+ <part name="result" type="xsd:boolean"/></message>
+ <message name="isUserInRoleTest">
+ <part name="String_1" type="xsd:string"/></message>
+ <message name="isUserInRoleTestResponse">
+ <part name="result" type="xsd:boolean"/></message>
+ <portType name="Hello">
+ <operation name="hello" parameterOrder="String_1">
+ <input message="tns:Hello_hello"/>
+ <output message="tns:Hello_helloResponse"/></operation>
+ <operation name="getMessageContextTest" >
+ <input message="tns:getMessageContextTest"/>
+ <output
message="tns:getMessageContextTestResponse"/></operation>
+ <operation name="getServletContextTest" >
+ <input message="tns:getServletContextTest"/>
+ <output
message="tns:getServletContextTestResponse"/></operation>
+ <operation name="getUserPrincipalTest" >
+ <input message="tns:getUserPrincipalTest"/>
+ <output
message="tns:getUserPrincipalTestResponse"/></operation>
+ <operation name="isUserInRoleTest"
parameterOrder="String_1">
+ <input message="tns:isUserInRoleTest"/>
+ <output message="tns:isUserInRoleTestResponse"/></operation>
+ </portType>
+ <binding name="HelloBinding" type="tns:Hello">
+ <soap:binding
transport="http://schemas.xmlsoap.org/soap/http"
style="rpc"/>
+ <operation name="hello">
+ <soap:operation soapAction=""/>
+ <input>
+ <soap:body use="literal"
namespace="http://helloservice.org/wsdl"/></input>
+ <output>
+ <soap:body use="literal"
namespace="http://helloservice.org/wsdl"/></output><...
+ <operation name="getMessageContextTest">
+ <soap:operation soapAction=""/>
+ <input>
+ <soap:body use="literal"
namespace="http://helloservice.org/wsdl"/></input>
+ <output>
+ <soap:body use="literal"
namespace="http://helloservice.org/wsdl"/></output><...
+ <operation name="getServletContextTest">
+ <soap:operation soapAction=""/>
+ <input>
+ <soap:body use="literal"
namespace="http://helloservice.org/wsdl"/></input>
+ <output>
+ <soap:body use="literal"
namespace="http://helloservice.org/wsdl"/></output><...
+ <operation name="getUserPrincipalTest">
+ <soap:operation soapAction=""/>
+ <input>
+ <soap:body use="literal"
namespace="http://helloservice.org/wsdl"/></input>
+ <output>
+ <soap:body use="literal"
namespace="http://helloservice.org/wsdl"/></output><...
+ <operation name="isUserInRoleTest">
+ <soap:operation soapAction=""/>
+ <input>
+ <soap:body use="literal"
namespace="http://helloservice.org/wsdl"/></input>
+ <output>
+ <soap:body use="literal"
namespace="http://helloservice.org/wsdl"/></output><...
+ </binding>
+ <service name="HelloService">
+ <port name="HelloPort" binding="tns:HelloBinding">
+ <soap:address
location="http://localhost:8080/jaxws-jbws2307-service/jaxws/Hello"/></port></service></definitions>
\ No newline at end of file
Added:
framework/trunk/testsuite/test/resources/jaxws/jbws2307/WEB-INF-service/jboss-web.xml
===================================================================
--- framework/trunk/testsuite/test/resources/jaxws/jbws2307/WEB-INF-service/jboss-web.xml
(rev 0)
+++
framework/trunk/testsuite/test/resources/jaxws/jbws2307/WEB-INF-service/jboss-web.xml 2009-02-07
12:12:19 UTC (rev 9257)
@@ -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>
+ <security-domain>java:/jaas/JBossWS</security-domain>
+</jboss-web>
\ No newline at end of file
Added: framework/trunk/testsuite/test/resources/jaxws/jbws2307/WEB-INF-service/web.xml
===================================================================
--- framework/trunk/testsuite/test/resources/jaxws/jbws2307/WEB-INF-service/web.xml
(rev 0)
+++
framework/trunk/testsuite/test/resources/jaxws/jbws2307/WEB-INF-service/web.xml 2009-02-07
12:12:19 UTC (rev 9257)
@@ -0,0 +1,70 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<web-app version="2.5"
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/web-app_2_5.xsd">
+
+ <display-name>jbws2307_testcase_service</display-name>
+ <servlet>
+ <servlet-name>HelloImpl</servlet-name>
+
<servlet-class>org.jboss.test.ws.jaxws.jbws2307.HelloImpl</servlet-class>
+ <load-on-startup>0</load-on-startup>
+ <security-role-ref>
+ <role-name>FRN</role-name>
+ <role-link>friend</role-link>
+ </security-role-ref>
+ <!-- <security-role-ref>
+ <role-name>ADM</role-name>
+ <role-link>Administrator</role-link>
+ </security-role-ref>
+ <security-role-ref>
+ <role-name>MGR</role-name>
+ <role-link>Manager</role-link>
+ </security-role-ref>
+ <security-role-ref>
+ <role-name>EMP</role-name>
+ <role-link>Employee</role-link>
+ </security-role-ref> -->
+ </servlet>
+ <servlet-mapping>
+ <servlet-name>HelloImpl</servlet-name>
+ <url-pattern>/jaxws/Hello</url-pattern>
+ </servlet-mapping>
+ <session-config>
+ <session-timeout>54</session-timeout>
+ </session-config>
+ <security-constraint>
+ <web-resource-collection>
+ <web-resource-name>WSHelloSecureService</web-resource-name>
+ <url-pattern>/jaxws/*</url-pattern>
+ <http-method>POST</http-method>
+ </web-resource-collection>
+ <!-- <auth-constraint>
+ <role-name>Administrator</role-name>
+ </auth-constraint> -->
+ <auth-constraint>
+ <role-name>friend</role-name>
+ </auth-constraint>
+ <user-data-constraint>
+ <transport-guarantee>NONE</transport-guarantee>
+ </user-data-constraint>
+ </security-constraint>
+ <login-config>
+ <auth-method>BASIC</auth-method>
+ <realm-name>default</realm-name>
+ </login-config>
+ <!-- <security-role>
+ <role-name>Administrator</role-name>
+ </security-role>
+ <security-role>
+ <role-name>Manager</role-name>
+ </security-role>
+ <security-role>
+ <role-name>Employee</role-name>
+ </security-role>
+ <security-role>
+ <role-name>Guest</role-name>
+ </security-role> -->
+ <security-role>
+ <role-name>friend</role-name>
+ </security-role>
+</web-app>
\ No newline at end of file
Added:
framework/trunk/testsuite/test/resources/jaxws/jbws2307/WEB-INF-service/wsdl/HelloService.wsdl
===================================================================
---
framework/trunk/testsuite/test/resources/jaxws/jbws2307/WEB-INF-service/wsdl/HelloService.wsdl
(rev 0)
+++
framework/trunk/testsuite/test/resources/jaxws/jbws2307/WEB-INF-service/wsdl/HelloService.wsdl 2009-02-07
12:12:19 UTC (rev 9257)
@@ -0,0 +1,74 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<definitions name="HelloService"
targetNamespace="http://helloservice.org/wsdl"
xmlns:tns="http://helloservice.org/wsdl"
xmlns="http://schemas.xmlsoap.org/wsdl/"
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/">
+ <types/>
+ <message name="Hello_hello">
+ <part name="String_1" type="xsd:string"/></message>
+ <message name="Hello_helloResponse">
+ <part name="result" type="xsd:string"/></message>
+ <message name="getMessageContextTest"/>
+ <message name="getMessageContextTestResponse">
+ <part name="result" type="xsd:boolean"/></message>
+ <message name="getServletContextTest"/>
+ <message name="getServletContextTestResponse">
+ <part name="result" type="xsd:boolean"/></message>
+ <message name="getUserPrincipalTest"/>
+ <message name="getUserPrincipalTestResponse">
+ <part name="result" type="xsd:boolean"/></message>
+ <message name="isUserInRoleTest">
+ <part name="String_1" type="xsd:string"/></message>
+ <message name="isUserInRoleTestResponse">
+ <part name="result" type="xsd:boolean"/></message>
+ <portType name="Hello">
+ <operation name="hello" parameterOrder="String_1">
+ <input message="tns:Hello_hello"/>
+ <output message="tns:Hello_helloResponse"/></operation>
+ <operation name="getMessageContextTest" >
+ <input message="tns:getMessageContextTest"/>
+ <output
message="tns:getMessageContextTestResponse"/></operation>
+ <operation name="getServletContextTest" >
+ <input message="tns:getServletContextTest"/>
+ <output
message="tns:getServletContextTestResponse"/></operation>
+ <operation name="getUserPrincipalTest" >
+ <input message="tns:getUserPrincipalTest"/>
+ <output
message="tns:getUserPrincipalTestResponse"/></operation>
+ <operation name="isUserInRoleTest"
parameterOrder="String_1">
+ <input message="tns:isUserInRoleTest"/>
+ <output message="tns:isUserInRoleTestResponse"/></operation>
+ </portType>
+ <binding name="HelloBinding" type="tns:Hello">
+ <soap:binding
transport="http://schemas.xmlsoap.org/soap/http"
style="rpc"/>
+ <operation name="hello">
+ <soap:operation soapAction=""/>
+ <input>
+ <soap:body use="literal"
namespace="http://helloservice.org/wsdl"/></input>
+ <output>
+ <soap:body use="literal"
namespace="http://helloservice.org/wsdl"/></output><...
+ <operation name="getMessageContextTest">
+ <soap:operation soapAction=""/>
+ <input>
+ <soap:body use="literal"
namespace="http://helloservice.org/wsdl"/></input>
+ <output>
+ <soap:body use="literal"
namespace="http://helloservice.org/wsdl"/></output><...
+ <operation name="getServletContextTest">
+ <soap:operation soapAction=""/>
+ <input>
+ <soap:body use="literal"
namespace="http://helloservice.org/wsdl"/></input>
+ <output>
+ <soap:body use="literal"
namespace="http://helloservice.org/wsdl"/></output><...
+ <operation name="getUserPrincipalTest">
+ <soap:operation soapAction=""/>
+ <input>
+ <soap:body use="literal"
namespace="http://helloservice.org/wsdl"/></input>
+ <output>
+ <soap:body use="literal"
namespace="http://helloservice.org/wsdl"/></output><...
+ <operation name="isUserInRoleTest">
+ <soap:operation soapAction=""/>
+ <input>
+ <soap:body use="literal"
namespace="http://helloservice.org/wsdl"/></input>
+ <output>
+ <soap:body use="literal"
namespace="http://helloservice.org/wsdl"/></output><...
+ </binding>
+ <service name="HelloService">
+ <port name="HelloPort" binding="tns:HelloBinding">
+ <soap:address
location="http://localhost:8080/jaxws-jbws2307-service/jaxws/Hello"/></port></service></definitions>
\ No newline at end of file