Author: darran.lofthouse(a)jboss.com
Date: 2006-10-16 11:32:34 -0400 (Mon, 16 Oct 2006)
New Revision: 1229
Added:
branches/dlofthouse/JBWS-1133/src/test/java/org/jboss/test/ws/jaxws/jbws1133/
branches/dlofthouse/JBWS-1133/src/test/java/org/jboss/test/ws/jaxws/jbws1133/JBWS1133TestCase.java
branches/dlofthouse/JBWS-1133/src/test/java/org/jboss/test/ws/jaxws/jbws1133/TestEndpoint.java
branches/dlofthouse/JBWS-1133/src/test/resources/jaxws/jbws1133/
branches/dlofthouse/JBWS-1133/src/test/resources/jaxws/jbws1133/WEB-INF/
branches/dlofthouse/JBWS-1133/src/test/resources/jaxws/jbws1133/WEB-INF/web.xml
Modified:
branches/dlofthouse/JBWS-1133/src/test/ant/build-jars-jaxws.xml
Log:
JBWS-1133 - Test Case
Modified: branches/dlofthouse/JBWS-1133/src/test/ant/build-jars-jaxws.xml
===================================================================
--- branches/dlofthouse/JBWS-1133/src/test/ant/build-jars-jaxws.xml 2006-10-16 15:30:38
UTC (rev 1228)
+++ branches/dlofthouse/JBWS-1133/src/test/ant/build-jars-jaxws.xml 2006-10-16 15:32:34
UTC (rev 1229)
@@ -74,6 +74,18 @@
<include
name="org/jboss/test/ws/jaxws/jbws1123/MessageBean.class"/>
</classes>
</war>
+
+ <!-- jaxws-jbws1133 -->
+ <mkdir dir="${build.test.dir}/libs/jaxws-jbws1133.war"/>
+ <mkdir dir="${build.test.dir}/libs/jaxws-jbws1133.war/WEB-INF"/>
+ <mkdir
dir="${build.test.dir}/libs/jaxws-jbws1133.war/WEB-INF/classes"/>
+ <copy
tofile="${build.test.dir}/libs/jaxws-jbws1133.war/WEB-INF/original-web.xml"
+
file="${build.test.dir}/resources/jaxws/jbws1133/WEB-INF/web.xml"/>
+ <copy
todir="${build.test.dir}/libs/jaxws-jbws1133.war/WEB-INF/classes">
+ <fileset dir="${build.test.dir}/classes">
+ <include
name="org/jboss/test/ws/jaxws/jbws1133/TestEndpoint.class"/>
+ </fileset>
+ </copy>
<!-- jaxws-jbws1178 -->
<war destfile="${build.test.dir}/libs/jaxws-jbws1178.war"
webxml="${build.test.dir}/resources/jaxws/jbws1178/WEB-INF/web.xml">
Added:
branches/dlofthouse/JBWS-1133/src/test/java/org/jboss/test/ws/jaxws/jbws1133/JBWS1133TestCase.java
===================================================================
---
branches/dlofthouse/JBWS-1133/src/test/java/org/jboss/test/ws/jaxws/jbws1133/JBWS1133TestCase.java 2006-10-16
15:30:38 UTC (rev 1228)
+++
branches/dlofthouse/JBWS-1133/src/test/java/org/jboss/test/ws/jaxws/jbws1133/JBWS1133TestCase.java 2006-10-16
15:32:34 UTC (rev 1229)
@@ -0,0 +1,80 @@
+/*
+ * 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.jbws1133;
+
+import java.io.File;
+import java.io.InputStream;
+import java.net.URL;
+
+import org.apache.tools.ant.util.FileUtils;
+import org.jboss.test.ws.JBossWSTest;
+
+/**
+ *
+ * @author darran.lofthouse(a)jboss.com
+ * @since 16-October-2006
+ */
+public class JBWS1133TestCase extends JBossWSTest
+{
+
+ private final String TARGET_WSDL = "http://" + getServerHost() +
":8080/jaxws-jbws1133?wsdl";
+
+ public void testRedeployExploded() throws Exception
+ {
+ cleanWebXML();
+
+ try
+ {
+ deploy("jaxws-jbws1133.war");
+
+ checkWSDL();
+
+ undeploy("jaxws-jbws1133.war");
+ deploy("jaxws-jbws1133.war");
+
+ checkWSDL();
+ }
+ finally
+ {
+ undeploy("jaxws-jbws1133.war");
+ }
+ }
+
+ private void cleanWebXML() throws Exception
+ {
+ File webXML = new File("libs/jaxws-jbws1133.war/WEB-INF/web.xml");
+ if (webXML.exists())
+ {
+ webXML.delete();
+ }
+ File originalWebXML = new
File("libs/jaxws-jbws1133.war/WEB-INF/original-web.xml");
+ FileUtils.getFileUtils().copyFile(originalWebXML, webXML);
+ }
+
+ private void checkWSDL() throws Exception
+ {
+ URL wsdlURL = new URL(TARGET_WSDL);
+ InputStream is = wsdlURL.openStream();
+ assertNotNull(is);
+ }
+
+}
Property changes on:
branches/dlofthouse/JBWS-1133/src/test/java/org/jboss/test/ws/jaxws/jbws1133/JBWS1133TestCase.java
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Added:
branches/dlofthouse/JBWS-1133/src/test/java/org/jboss/test/ws/jaxws/jbws1133/TestEndpoint.java
===================================================================
---
branches/dlofthouse/JBWS-1133/src/test/java/org/jboss/test/ws/jaxws/jbws1133/TestEndpoint.java 2006-10-16
15:30:38 UTC (rev 1228)
+++
branches/dlofthouse/JBWS-1133/src/test/java/org/jboss/test/ws/jaxws/jbws1133/TestEndpoint.java 2006-10-16
15:32:34 UTC (rev 1229)
@@ -0,0 +1,44 @@
+/*
+ * 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.jbws1133;
+
+import javax.jws.WebMethod;
+import javax.jws.WebService;
+import javax.jws.soap.SOAPBinding;
+
+/**
+ *
+ * @author darran.lofthouse(a)jboss.com
+ * @since 16-October-2006
+ */
+@WebService(targetNamespace = "http://org.jboss/test/ws/jbws1133")
+@SOAPBinding(style = SOAPBinding.Style.DOCUMENT)
+public class TestEndpoint
+{
+
+ @WebMethod
+ public String echo(final String message)
+ {
+ return message;
+ }
+
+}
Property changes on:
branches/dlofthouse/JBWS-1133/src/test/java/org/jboss/test/ws/jaxws/jbws1133/TestEndpoint.java
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Added: branches/dlofthouse/JBWS-1133/src/test/resources/jaxws/jbws1133/WEB-INF/web.xml
===================================================================
---
branches/dlofthouse/JBWS-1133/src/test/resources/jaxws/jbws1133/WEB-INF/web.xml 2006-10-16
15:30:38 UTC (rev 1228)
+++
branches/dlofthouse/JBWS-1133/src/test/resources/jaxws/jbws1133/WEB-INF/web.xml 2006-10-16
15:32:34 UTC (rev 1229)
@@ -0,0 +1,15 @@
+<?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>TestEndpoint</servlet-name>
+
<servlet-class>org.jboss.test.ws.jaxws.jbws1133.TestEndpoint</servlet-class>
+ </servlet>
+
+ <servlet-mapping>
+ <servlet-name>TestEndpoint</servlet-name>
+ <url-pattern>/*</url-pattern>
+ </servlet-mapping>
+</web-app>
\ No newline at end of file
Property changes on:
branches/dlofthouse/JBWS-1133/src/test/resources/jaxws/jbws1133/WEB-INF/web.xml
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF