Author: richard.opalka(a)jboss.com
Date: 2007-12-17 06:57:30 -0500 (Mon, 17 Dec 2007)
New Revision: 5329
Added:
stack/native/trunk/src/test/java/org/jboss/test/ws/jaxws/wsrm/oneway/RMAbstractSecuredOneWayTest.java
stack/native/trunk/src/test/java/org/jboss/test/ws/jaxws/wsrm/oneway/RMSecuredAddressableOneWayTestCase.java
stack/native/trunk/src/test/java/org/jboss/test/ws/jaxws/wsrm/oneway/RMSecuredAnonymousOneWayTestCase.java
stack/native/trunk/src/test/java/org/jboss/test/ws/jaxws/wsrm/reqres/RMAbstractSecuredReqResTest.java
stack/native/trunk/src/test/java/org/jboss/test/ws/jaxws/wsrm/reqres/RMSecuredAddressableReqResTestCase.java
stack/native/trunk/src/test/java/org/jboss/test/ws/jaxws/wsrm/reqres/RMSecuredAnonymousReqResTestCase.java
stack/native/trunk/src/test/resources/jaxws/wsrm/WEB-INF/secure/
stack/native/trunk/src/test/resources/jaxws/wsrm/WEB-INF/secure/web.xml
stack/native/trunk/src/test/resources/jaxws/wsrm/properties/RMAbstractSecuredOneWayTest.properties
stack/native/trunk/src/test/resources/jaxws/wsrm/properties/RMAbstractSecuredReqResTest.properties
Modified:
stack/native/trunk/ant-import-tests/build-jars-jaxws.xml
stack/native/trunk/src/test/java/org/jboss/test/ws/jaxws/wsrm/oneway/RMAbstractOneWayTest.java
stack/native/trunk/src/test/java/org/jboss/test/ws/jaxws/wsrm/oneway/RMAddressableOneWayTestCase.java
stack/native/trunk/src/test/java/org/jboss/test/ws/jaxws/wsrm/reqres/RMAbstractReqResTest.java
stack/native/trunk/src/test/java/org/jboss/test/ws/jaxws/wsrm/reqres/RMAnonymousReqResTestCase.java
stack/native/trunk/src/test/java/org/jboss/test/ws/jaxws/wsrm/services/SecuredOneWayServiceIface.java
stack/native/trunk/src/test/java/org/jboss/test/ws/jaxws/wsrm/services/SecuredOneWayServiceImpl.java
stack/native/trunk/src/test/java/org/jboss/test/ws/jaxws/wsrm/services/SecuredReqResServiceIface.java
stack/native/trunk/src/test/java/org/jboss/test/ws/jaxws/wsrm/services/SecuredReqResServiceImpl.java
Log:
prepared WS-RM + WS-Security test case (but WS-Security isn't integrated into test
yet)
Modified: stack/native/trunk/ant-import-tests/build-jars-jaxws.xml
===================================================================
--- stack/native/trunk/ant-import-tests/build-jars-jaxws.xml 2007-12-17 11:07:18 UTC (rev
5328)
+++ stack/native/trunk/ant-import-tests/build-jars-jaxws.xml 2007-12-17 11:57:30 UTC (rev
5329)
@@ -669,6 +669,20 @@
</webinf>
</war>
+ <war warfile="${tests.output.dir}/libs/jaxws-secured-wsrm.war"
+
webxml="${tests.output.dir}/resources/jaxws/wsrm/WEB-INF/secure/web.xml">
+ <classes dir="${tests.output.dir}/classes">
+ <include
name="org/jboss/test/ws/jaxws/wsrm/services/SecuredOneWayServiceIface.class"/>
+ <include
name="org/jboss/test/ws/jaxws/wsrm/services/SecuredOneWayServiceImpl.class"/>
+ <include
name="org/jboss/test/ws/jaxws/wsrm/services/SecuredReqResServiceIface.class"/>
+ <include
name="org/jboss/test/ws/jaxws/wsrm/services/SecuredReqResServiceImpl.class"/>
+ </classes>
+ <webinf dir="${tests.output.dir}/resources/jaxws/wsrm/WEB-INF">
+ <include name="wsrm-exactly-once-in-order-policy.xml"/>
+ <include name="wsrm-jaxws-endpoint-config.xml"/>
+ </webinf>
+ </war>
+
<war warfile="${tests.output.dir}/libs/jaxws-wsrm-one-way-emulator.war"
webxml="${tests.output.dir}/resources/jaxws/wsrm/emulator/oneway/WEB-INF/web.xml">
<classes dir="${tests.output.dir}/classes">
@@ -695,6 +709,12 @@
</metainf>
</jar>
+ <jar
jarfile="${tests.output.dir}/libs/jaxws-secured-wsrm-client.jar">
+ <metainf dir="${tests.output.dir}/resources/jaxws/wsrm/META-INF">
+ <include name="wsrm-jaxws-client-config.xml"/>
+ </metainf>
+ </jar>
+
<!-- Please add alphabetically -->
<antcall target="build-interop-jars"/>
Modified:
stack/native/trunk/src/test/java/org/jboss/test/ws/jaxws/wsrm/oneway/RMAbstractOneWayTest.java
===================================================================
---
stack/native/trunk/src/test/java/org/jboss/test/ws/jaxws/wsrm/oneway/RMAbstractOneWayTest.java 2007-12-17
11:07:18 UTC (rev 5328)
+++
stack/native/trunk/src/test/java/org/jboss/test/ws/jaxws/wsrm/oneway/RMAbstractOneWayTest.java 2007-12-17
11:57:30 UTC (rev 5329)
@@ -41,7 +41,8 @@
* Reliable JBoss WebService client invoking one way methods
*
* @author richard.opalka(a)jboss.com
- * @since 22-Aug-2007
+ *
+ * @since Aug 22, 2007
*/
public abstract class RMAbstractOneWayTest extends JBossWSTest
{
@@ -93,5 +94,4 @@
}
protected abstract boolean isClientAddressable();
-
}
Added:
stack/native/trunk/src/test/java/org/jboss/test/ws/jaxws/wsrm/oneway/RMAbstractSecuredOneWayTest.java
===================================================================
---
stack/native/trunk/src/test/java/org/jboss/test/ws/jaxws/wsrm/oneway/RMAbstractSecuredOneWayTest.java
(rev 0)
+++
stack/native/trunk/src/test/java/org/jboss/test/ws/jaxws/wsrm/oneway/RMAbstractSecuredOneWayTest.java 2007-12-17
11:57:30 UTC (rev 5329)
@@ -0,0 +1,98 @@
+/*
+ * 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.wsrm.oneway;
+
+import static org.jboss.test.ws.jaxws.wsrm.Helper.setAddrProps;
+
+import java.io.File;
+import java.io.FileInputStream;
+import java.io.IOException;
+import java.net.URL;
+import java.util.Properties;
+
+import javax.xml.namespace.QName;
+import javax.xml.ws.Service;
+
+import org.jboss.test.ws.jaxws.wsrm.services.SecuredOneWayServiceIface;
+import org.jboss.ws.extensions.wsrm.api.RMProvider;
+import org.jboss.ws.extensions.wsrm.api.RMSequence;
+import org.jboss.wsf.test.JBossWSTest;
+
+/**
+ * Secure Reliable JBoss WebService client invoking one way methods
+ *
+ * @author richard.opalka(a)jboss.com
+ *
+ * @since Dec 17, 2007
+ */
+public abstract class RMAbstractSecuredOneWayTest extends JBossWSTest
+{
+ private static final Properties props = new Properties();
+ private final String serviceURL = "http://" + getServerHost() +
":" + props.getProperty("port") +
props.getProperty("path");
+ private String targetNS = "http://org.jboss.ws/jaxws/wsrm";
+ private SecuredOneWayServiceIface proxy;
+
+ static
+ {
+ try
+ {
+ props.load(
+ new FileInputStream(
+ new
File("resources/jaxws/wsrm/properties/RMAbstractSecuredOneWayTest.properties")));
+ }
+ catch (IOException ioe)
+ {
+ ioe.printStackTrace();
+ }
+ }
+
+ @Override
+ protected void setUp() throws Exception
+ {
+ super.setUp();
+
+ QName serviceName = new QName(targetNS, "SecuredOneWayService");
+ URL wsdlURL = new URL(serviceURL + "?wsdl");
+ Service service = Service.create(wsdlURL, serviceName);
+ proxy =
(SecuredOneWayServiceIface)service.getPort(SecuredOneWayServiceIface.class);
+ // TODO: activate WS-Security
+ }
+
+ public void testOneWayMethods() throws Exception
+ {
+ RMSequence sequence = ((RMProvider)proxy).createSequence(isClientAddressable());
+ setAddrProps(proxy, "http://useless/action1", serviceURL);
+ proxy.method1();
+ setAddrProps(proxy, "http://useless/action2", serviceURL);
+ proxy.method2("Hello World");
+ setAddrProps(proxy, "http://useless/action3", serviceURL);
+ proxy.method3(new String[] {"Hello","World"});
+ sequence.close();
+ }
+
+ public static String getClasspath()
+ {
+ return props.getProperty("archives");
+ }
+
+ protected abstract boolean isClientAddressable();
+}
Property changes on:
stack/native/trunk/src/test/java/org/jboss/test/ws/jaxws/wsrm/oneway/RMAbstractSecuredOneWayTest.java
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Modified:
stack/native/trunk/src/test/java/org/jboss/test/ws/jaxws/wsrm/oneway/RMAddressableOneWayTestCase.java
===================================================================
---
stack/native/trunk/src/test/java/org/jboss/test/ws/jaxws/wsrm/oneway/RMAddressableOneWayTestCase.java 2007-12-17
11:07:18 UTC (rev 5328)
+++
stack/native/trunk/src/test/java/org/jboss/test/ws/jaxws/wsrm/oneway/RMAddressableOneWayTestCase.java 2007-12-17
11:57:30 UTC (rev 5329)
@@ -34,7 +34,6 @@
*/
public final class RMAddressableOneWayTestCase extends RMAbstractOneWayTest
{
-
public static Test suite()
{
return new JBossWSTestSetup(RMAddressableOneWayTestCase.class, getClasspath());
@@ -44,5 +43,4 @@
{
return true;
}
-
}
Added:
stack/native/trunk/src/test/java/org/jboss/test/ws/jaxws/wsrm/oneway/RMSecuredAddressableOneWayTestCase.java
===================================================================
---
stack/native/trunk/src/test/java/org/jboss/test/ws/jaxws/wsrm/oneway/RMSecuredAddressableOneWayTestCase.java
(rev 0)
+++
stack/native/trunk/src/test/java/org/jboss/test/ws/jaxws/wsrm/oneway/RMSecuredAddressableOneWayTestCase.java 2007-12-17
11:57:30 UTC (rev 5329)
@@ -0,0 +1,46 @@
+/*
+ * 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.wsrm.oneway;
+
+import junit.framework.Test;
+
+import org.jboss.wsf.test.JBossWSTestSetup;
+
+/**
+ * Secured addressable version of one way WS-RM message exchange
+ *
+ * @author richard.opalka(a)jboss.com
+ *
+ * @since Dec 17, 2007
+ */
+public class RMSecuredAddressableOneWayTestCase extends RMAbstractSecuredOneWayTest
+{
+ public static Test suite()
+ {
+ return new JBossWSTestSetup(RMSecuredAddressableOneWayTestCase.class,
getClasspath());
+ }
+
+ public final boolean isClientAddressable()
+ {
+ return true;
+ }
+}
Property changes on:
stack/native/trunk/src/test/java/org/jboss/test/ws/jaxws/wsrm/oneway/RMSecuredAddressableOneWayTestCase.java
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Added:
stack/native/trunk/src/test/java/org/jboss/test/ws/jaxws/wsrm/oneway/RMSecuredAnonymousOneWayTestCase.java
===================================================================
---
stack/native/trunk/src/test/java/org/jboss/test/ws/jaxws/wsrm/oneway/RMSecuredAnonymousOneWayTestCase.java
(rev 0)
+++
stack/native/trunk/src/test/java/org/jboss/test/ws/jaxws/wsrm/oneway/RMSecuredAnonymousOneWayTestCase.java 2007-12-17
11:57:30 UTC (rev 5329)
@@ -0,0 +1,46 @@
+/*
+ * 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.wsrm.oneway;
+
+import junit.framework.Test;
+
+import org.jboss.wsf.test.JBossWSTestSetup;
+
+/**
+ * Secured anonymous version of one way WS-RM message exchange
+ *
+ * @author richard.opalka(a)jboss.com
+ *
+ * @since Dec 17, 2007
+ */
+public class RMSecuredAnonymousOneWayTestCase extends RMAbstractSecuredOneWayTest
+{
+ public static Test suite()
+ {
+ return new JBossWSTestSetup(RMSecuredAnonymousOneWayTestCase.class,
getClasspath());
+ }
+
+ public final boolean isClientAddressable()
+ {
+ return false;
+ }
+}
Property changes on:
stack/native/trunk/src/test/java/org/jboss/test/ws/jaxws/wsrm/oneway/RMSecuredAnonymousOneWayTestCase.java
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Modified:
stack/native/trunk/src/test/java/org/jboss/test/ws/jaxws/wsrm/reqres/RMAbstractReqResTest.java
===================================================================
---
stack/native/trunk/src/test/java/org/jboss/test/ws/jaxws/wsrm/reqres/RMAbstractReqResTest.java 2007-12-17
11:07:18 UTC (rev 5328)
+++
stack/native/trunk/src/test/java/org/jboss/test/ws/jaxws/wsrm/reqres/RMAbstractReqResTest.java 2007-12-17
11:57:30 UTC (rev 5329)
@@ -49,7 +49,8 @@
* Reliable JBoss WebService client invoking req/res methods
*
* @author richard.opalka(a)jboss.com
- * @since 22-Aug-2007
+ *
+ * @since Aug 22, 2007
*/
public abstract class RMAbstractReqResTest extends JBossWSTest
{
Added:
stack/native/trunk/src/test/java/org/jboss/test/ws/jaxws/wsrm/reqres/RMAbstractSecuredReqResTest.java
===================================================================
---
stack/native/trunk/src/test/java/org/jboss/test/ws/jaxws/wsrm/reqres/RMAbstractSecuredReqResTest.java
(rev 0)
+++
stack/native/trunk/src/test/java/org/jboss/test/ws/jaxws/wsrm/reqres/RMAbstractSecuredReqResTest.java 2007-12-17
11:57:30 UTC (rev 5329)
@@ -0,0 +1,189 @@
+/*
+ * 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.wsrm.reqres;
+
+import static org.jboss.test.ws.jaxws.wsrm.Helper.setAddrProps;
+
+import java.io.File;
+import java.io.FileInputStream;
+import java.io.IOException;
+import java.net.URL;
+import java.util.Properties;
+import java.util.concurrent.Executor;
+import java.util.concurrent.Future;
+import java.util.concurrent.SynchronousQueue;
+import java.util.concurrent.ThreadPoolExecutor;
+import java.util.concurrent.TimeUnit;
+
+import javax.xml.namespace.QName;
+import javax.xml.ws.AsyncHandler;
+import javax.xml.ws.Response;
+import javax.xml.ws.Service;
+
+import org.jboss.test.ws.jaxws.wsrm.services.SecuredReqResServiceIface;
+import org.jboss.ws.extensions.wsrm.api.RMProvider;
+import org.jboss.ws.extensions.wsrm.api.RMSequence;
+import org.jboss.wsf.test.JBossWSTest;
+
+/**
+ * Secured reliable JBoss WebService client invoking req/res methods
+ *
+ * @author richard.opalka(a)jboss.com
+ *
+ * @since Dec 17, 2007
+ */
+public abstract class RMAbstractSecuredReqResTest extends JBossWSTest
+{
+ private static final String HELLO_WORLD_MSG = "Hello World";
+ private static final String TARGET_NS = "http://org.jboss.ws/jaxws/wsrm";
+ private static final Properties props = new Properties();
+ private final String serviceURL = "http://" + getServerHost() +
":" + props.getProperty("port") +
props.getProperty("path");
+ private Exception handlerException;
+ private boolean asyncHandlerCalled;
+ private SecuredReqResServiceIface proxy;
+ private static final TimeUnit testTimeUnit = TimeUnit.SECONDS;
+ private static final long testWaitPeriod = 300L;
+ private static final Executor testExecutor = new ThreadPoolExecutor(
+ 0, 5, testWaitPeriod, testTimeUnit, new SynchronousQueue<Runnable>()
+ );
+
+ static
+ {
+ try
+ {
+ props.load(
+ new FileInputStream(
+ new
File("resources/jaxws/wsrm/properties/RMAbstractSecuredReqResTest.properties")));
+ }
+ catch (IOException ioe)
+ {
+ ioe.printStackTrace();
+ }
+ }
+
+ private enum InvocationType
+ {
+ SYNC, ASYNC, ASYNC_FUTURE
+ }
+
+ @Override
+ protected void setUp() throws Exception
+ {
+ super.setUp();
+
+ if (proxy == null)
+ {
+ QName serviceName = new QName(TARGET_NS, "SecuredReqResService");
+ URL wsdlURL = new URL(serviceURL + "?wsdl");
+ Service service = Service.create(wsdlURL, serviceName);
+ service.setExecutor(testExecutor);
+ proxy =
(SecuredReqResServiceIface)service.getPort(SecuredReqResServiceIface.class);
+ // TODO: activate WS-Security
+ }
+ }
+
+ public void testSynchronousInvocation() throws Exception
+ {
+ doReliableMessageExchange(proxy, InvocationType.SYNC);
+ }
+
+ public void testAsynchronousInvocation() throws Exception
+ {
+ doReliableMessageExchange(proxy, InvocationType.ASYNC);
+ }
+
+ public void testAsynchronousInvocationUsingFuture() throws Exception
+ {
+ doReliableMessageExchange(proxy, InvocationType.ASYNC_FUTURE);
+ }
+
+ private void doSynchronousInvocation() throws Exception
+ {
+ assertEquals(proxy.echo(HELLO_WORLD_MSG), HELLO_WORLD_MSG);
+ }
+
+ private void doAsynchronousInvocation() throws Exception
+ {
+ Response<String> response = proxy.echoAsync(HELLO_WORLD_MSG);
+ assertEquals(response.get(), HELLO_WORLD_MSG); // hidden future pattern
+ }
+
+ private void doAsynchronousInvocationUsingFuture() throws Exception
+ {
+ AsyncHandler<String> handler = new AsyncHandler<String>()
+ {
+ public void handleResponse(Response<String> response)
+ {
+ try
+ {
+ String retStr = (String) response.get(testWaitPeriod, testTimeUnit);
+ assertEquals(HELLO_WORLD_MSG, retStr);
+ asyncHandlerCalled = true;
+ }
+ catch (Exception ex)
+ {
+ handlerException = ex;
+ }
+ }
+ };
+ Future<?> future = proxy.echoAsync(HELLO_WORLD_MSG, handler);
+ future.get(testWaitPeriod, testTimeUnit);
+ ensureAsyncStatus();
+ }
+
+ private void ensureAsyncStatus() throws Exception
+ {
+ if (handlerException != null) throw handlerException;
+ assertTrue("Async handler called", asyncHandlerCalled);
+ handlerException = null;
+ asyncHandlerCalled = false;
+ }
+
+ private void invokeWebServiceMethod(InvocationType invocationType) throws Exception
+ {
+ switch (invocationType) {
+ case SYNC: doSynchronousInvocation(); break;
+ case ASYNC: doAsynchronousInvocation(); break;
+ case ASYNC_FUTURE: doAsynchronousInvocationUsingFuture(); break;
+ default : fail("Unknown invocation type");
+ }
+ }
+
+ private void doReliableMessageExchange(Object proxyObject, InvocationType
invocationType) throws Exception
+ {
+ RMSequence sequence =
((RMProvider)proxyObject).createSequence(isClientAddressable());
+ setAddrProps(proxy, "http://useless/action", serviceURL);
+ invokeWebServiceMethod(invocationType);
+ setAddrProps(proxy, "http://useless/action", serviceURL);
+ invokeWebServiceMethod(invocationType);
+ setAddrProps(proxy, "http://useless/action", serviceURL);
+ invokeWebServiceMethod(invocationType);
+ sequence.close();
+ }
+
+ public static String getClasspath()
+ {
+ return props.getProperty("archives");
+ }
+
+ protected abstract boolean isClientAddressable();
+}
Property changes on:
stack/native/trunk/src/test/java/org/jboss/test/ws/jaxws/wsrm/reqres/RMAbstractSecuredReqResTest.java
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Modified:
stack/native/trunk/src/test/java/org/jboss/test/ws/jaxws/wsrm/reqres/RMAnonymousReqResTestCase.java
===================================================================
---
stack/native/trunk/src/test/java/org/jboss/test/ws/jaxws/wsrm/reqres/RMAnonymousReqResTestCase.java 2007-12-17
11:07:18 UTC (rev 5328)
+++
stack/native/trunk/src/test/java/org/jboss/test/ws/jaxws/wsrm/reqres/RMAnonymousReqResTestCase.java 2007-12-17
11:57:30 UTC (rev 5329)
@@ -34,7 +34,6 @@
*/
public final class RMAnonymousReqResTestCase extends RMAbstractReqResTest
{
-
public static Test suite()
{
return new JBossWSTestSetup(RMAnonymousReqResTestCase.class, getClasspath());
@@ -44,5 +43,4 @@
{
return false;
}
-
}
Added:
stack/native/trunk/src/test/java/org/jboss/test/ws/jaxws/wsrm/reqres/RMSecuredAddressableReqResTestCase.java
===================================================================
---
stack/native/trunk/src/test/java/org/jboss/test/ws/jaxws/wsrm/reqres/RMSecuredAddressableReqResTestCase.java
(rev 0)
+++
stack/native/trunk/src/test/java/org/jboss/test/ws/jaxws/wsrm/reqres/RMSecuredAddressableReqResTestCase.java 2007-12-17
11:57:30 UTC (rev 5329)
@@ -0,0 +1,46 @@
+/*
+ * 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.wsrm.reqres;
+
+import junit.framework.Test;
+
+import org.jboss.wsf.test.JBossWSTestSetup;
+
+/**
+ * Secured addressable version of request reply WS-RM message exchange
+ *
+ * @author richard.opalka(a)jboss.com
+ *
+ * @since Dec 17, 2007
+ */
+public class RMSecuredAddressableReqResTestCase extends RMAbstractSecuredReqResTest
+{
+ public static Test suite()
+ {
+ return new JBossWSTestSetup(RMSecuredAddressableReqResTestCase.class,
getClasspath());
+ }
+
+ public final boolean isClientAddressable()
+ {
+ return true;
+ }
+}
Property changes on:
stack/native/trunk/src/test/java/org/jboss/test/ws/jaxws/wsrm/reqres/RMSecuredAddressableReqResTestCase.java
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Added:
stack/native/trunk/src/test/java/org/jboss/test/ws/jaxws/wsrm/reqres/RMSecuredAnonymousReqResTestCase.java
===================================================================
---
stack/native/trunk/src/test/java/org/jboss/test/ws/jaxws/wsrm/reqres/RMSecuredAnonymousReqResTestCase.java
(rev 0)
+++
stack/native/trunk/src/test/java/org/jboss/test/ws/jaxws/wsrm/reqres/RMSecuredAnonymousReqResTestCase.java 2007-12-17
11:57:30 UTC (rev 5329)
@@ -0,0 +1,46 @@
+/*
+ * 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.wsrm.reqres;
+
+import junit.framework.Test;
+
+import org.jboss.wsf.test.JBossWSTestSetup;
+
+/**
+ * Secured anonymous version of request reply WS-RM message exchange
+ *
+ * @author richard.opalka(a)jboss.com
+ *
+ * @since Dec 17, 2007
+ */
+public class RMSecuredAnonymousReqResTestCase extends RMAbstractSecuredReqResTest
+{
+ public static Test suite()
+ {
+ return new JBossWSTestSetup(RMSecuredAnonymousReqResTestCase.class,
getClasspath());
+ }
+
+ public final boolean isClientAddressable()
+ {
+ return false;
+ }
+}
Property changes on:
stack/native/trunk/src/test/java/org/jboss/test/ws/jaxws/wsrm/reqres/RMSecuredAnonymousReqResTestCase.java
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Modified:
stack/native/trunk/src/test/java/org/jboss/test/ws/jaxws/wsrm/services/SecuredOneWayServiceIface.java
===================================================================
---
stack/native/trunk/src/test/java/org/jboss/test/ws/jaxws/wsrm/services/SecuredOneWayServiceIface.java 2007-12-17
11:07:18 UTC (rev 5328)
+++
stack/native/trunk/src/test/java/org/jboss/test/ws/jaxws/wsrm/services/SecuredOneWayServiceIface.java 2007-12-17
11:57:30 UTC (rev 5329)
@@ -29,7 +29,8 @@
@WebService
@EndpointConfig
(
- configName = "Secured WSRM Client",
+// configName = "Secured WSRM Client", TODO: uncommented
+ configName = "Standard WSRM Client",
configFile = "META-INF/wsrm-jaxws-client-config.xml"
)
public interface SecuredOneWayServiceIface
Modified:
stack/native/trunk/src/test/java/org/jboss/test/ws/jaxws/wsrm/services/SecuredOneWayServiceImpl.java
===================================================================
---
stack/native/trunk/src/test/java/org/jboss/test/ws/jaxws/wsrm/services/SecuredOneWayServiceImpl.java 2007-12-17
11:07:18 UTC (rev 5328)
+++
stack/native/trunk/src/test/java/org/jboss/test/ws/jaxws/wsrm/services/SecuredOneWayServiceImpl.java 2007-12-17
11:57:30 UTC (rev 5329)
@@ -49,7 +49,8 @@
)
@EndpointConfig
(
- configName = "Secured WSRM Endpoint",
+// configName = "Secured WSRM Endpoint", TODO: uncomment
+ configName = "Standard WSRM Endpoint",
configFile = "WEB-INF/wsrm-jaxws-endpoint-config.xml"
)
public class SecuredOneWayServiceImpl implements SecuredOneWayServiceIface
Modified:
stack/native/trunk/src/test/java/org/jboss/test/ws/jaxws/wsrm/services/SecuredReqResServiceIface.java
===================================================================
---
stack/native/trunk/src/test/java/org/jboss/test/ws/jaxws/wsrm/services/SecuredReqResServiceIface.java 2007-12-17
11:07:18 UTC (rev 5328)
+++
stack/native/trunk/src/test/java/org/jboss/test/ws/jaxws/wsrm/services/SecuredReqResServiceIface.java 2007-12-17
11:57:30 UTC (rev 5329)
@@ -33,6 +33,7 @@
@WebService
@EndpointConfig
(
+// configName = "Secured WSRM Client", TODO: uncomment
configName = "Standard WSRM Client",
configFile = "META-INF/wsrm-jaxws-client-config.xml"
)
Modified:
stack/native/trunk/src/test/java/org/jboss/test/ws/jaxws/wsrm/services/SecuredReqResServiceImpl.java
===================================================================
---
stack/native/trunk/src/test/java/org/jboss/test/ws/jaxws/wsrm/services/SecuredReqResServiceImpl.java 2007-12-17
11:07:18 UTC (rev 5328)
+++
stack/native/trunk/src/test/java/org/jboss/test/ws/jaxws/wsrm/services/SecuredReqResServiceImpl.java 2007-12-17
11:57:30 UTC (rev 5329)
@@ -22,10 +22,7 @@
package org.jboss.test.ws.jaxws.wsrm.services;
import javax.jws.WebMethod;
-import javax.jws.WebParam;
-import javax.jws.WebResult;
import javax.jws.WebService;
-import javax.xml.ws.addressing.Action;
import org.jboss.logging.Logger;
import org.jboss.ws.annotation.EndpointConfig;
@@ -50,6 +47,7 @@
)
@EndpointConfig
(
+// configName = "Standard WSRM Endpoint", TODO: uncomment
configName = "Standard WSRM Endpoint",
configFile = "WEB-INF/wsrm-jaxws-endpoint-config.xml"
)
Added: stack/native/trunk/src/test/resources/jaxws/wsrm/WEB-INF/secure/web.xml
===================================================================
--- stack/native/trunk/src/test/resources/jaxws/wsrm/WEB-INF/secure/web.xml
(rev 0)
+++ stack/native/trunk/src/test/resources/jaxws/wsrm/WEB-INF/secure/web.xml 2007-12-17
11:57:30 UTC (rev 5329)
@@ -0,0 +1,28 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<web-app
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"
+ version="2.4">
+
+ <servlet>
+ <servlet-name>SecuredOneWayService</servlet-name>
+
<servlet-class>org.jboss.test.ws.jaxws.wsrm.services.SecuredOneWayServiceImpl</servlet-class>
+ </servlet>
+
+ <servlet-mapping>
+ <servlet-name>SecuredOneWayService</servlet-name>
+ <url-pattern>/SecuredOneWayService</url-pattern>
+ </servlet-mapping>
+
+ <servlet>
+ <servlet-name>SecuredReqResService</servlet-name>
+
<servlet-class>org.jboss.test.ws.jaxws.wsrm.services.SecuredReqResServiceImpl</servlet-class>
+ </servlet>
+
+ <servlet-mapping>
+ <servlet-name>SecuredReqResService</servlet-name>
+ <url-pattern>/SecuredReqResService</url-pattern>
+ </servlet-mapping>
+
+</web-app>
Property changes on:
stack/native/trunk/src/test/resources/jaxws/wsrm/WEB-INF/secure/web.xml
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Added:
stack/native/trunk/src/test/resources/jaxws/wsrm/properties/RMAbstractSecuredOneWayTest.properties
===================================================================
---
stack/native/trunk/src/test/resources/jaxws/wsrm/properties/RMAbstractSecuredOneWayTest.properties
(rev 0)
+++
stack/native/trunk/src/test/resources/jaxws/wsrm/properties/RMAbstractSecuredOneWayTest.properties 2007-12-17
11:57:30 UTC (rev 5329)
@@ -0,0 +1,3 @@
+port=8080
+path=/jaxws-secured-wsrm/SecuredOneWayService
+archives=jaxws-secured-wsrm.war, jaxws-secured-wsrm-client.jar
Added:
stack/native/trunk/src/test/resources/jaxws/wsrm/properties/RMAbstractSecuredReqResTest.properties
===================================================================
---
stack/native/trunk/src/test/resources/jaxws/wsrm/properties/RMAbstractSecuredReqResTest.properties
(rev 0)
+++
stack/native/trunk/src/test/resources/jaxws/wsrm/properties/RMAbstractSecuredReqResTest.properties 2007-12-17
11:57:30 UTC (rev 5329)
@@ -0,0 +1,3 @@
+port=8080
+path=/jaxws-secured-wsrm/SecuredReqResService
+archives=jaxws-secured-wsrm.war, jaxws-secured-wsrm-client.jar