Author: thomas.diesler(a)jboss.com
Date: 2007-12-18 12:57:50 -0500 (Tue, 18 Dec 2007)
New Revision: 5355
Added:
stack/cxf/trunk/src/test/java/org/jboss/test/ws/jaxws/cxf/descriptor/DescriptorJSETestCase.java
stack/cxf/trunk/src/test/java/org/jboss/test/ws/jaxws/cxf/logging/
stack/cxf/trunk/src/test/java/org/jboss/test/ws/jaxws/cxf/logging/JDKLoggingTestCase.java
Removed:
stack/cxf/trunk/src/test/java/org/jboss/test/ws/jaxws/cxf/descriptor/DescriptorCXFJSETestCase.java
Modified:
stack/cxf/trunk/src/test/java/org/jboss/test/ws/jaxws/cxf/descriptor/DescriptorEndpoint.java
stack/cxf/trunk/src/test/java/org/jboss/test/ws/jaxws/cxf/descriptor/DescriptorEndpointImpl.java
stack/cxf/trunk/src/test/java/org/jboss/test/ws/jaxws/cxf/reliable/RMEndpoint.java
stack/cxf/trunk/src/test/java/org/jboss/test/ws/jaxws/cxf/reliable/RMEndpointImpl.java
Log:
Add JDK logging test case
Deleted:
stack/cxf/trunk/src/test/java/org/jboss/test/ws/jaxws/cxf/descriptor/DescriptorCXFJSETestCase.java
===================================================================
---
stack/cxf/trunk/src/test/java/org/jboss/test/ws/jaxws/cxf/descriptor/DescriptorCXFJSETestCase.java 2007-12-18
17:45:00 UTC (rev 5354)
+++
stack/cxf/trunk/src/test/java/org/jboss/test/ws/jaxws/cxf/descriptor/DescriptorCXFJSETestCase.java 2007-12-18
17:57:50 UTC (rev 5355)
@@ -1,61 +0,0 @@
-/*
- * 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.cxf.descriptor;
-
-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;
-
-/**
- * Test the CXF WS-descriptorMessaging
- *
- * @author Thomas.Diesler(a)jboss.org
- * @since 12-Dec-2007
- */
-public class DescriptorCXFJSETestCase extends JBossWSTest
-{
- private String endpointURL = "http://" + getServerHost() +
":8080/jaxws-cxf-descriptor/TestService";
- private String targetNS = "http://org.jboss.ws.jaxws.cxf/descriptor";
-
- public static Test suite()
- {
- return new JBossWSTestSetup(DescriptorCXFJSETestCase.class,
"jaxws-cxf-descriptor.war");
- }
-
- public void testLegalAccess() throws Exception
- {
- URL wsdlURL = new URL(endpointURL + "?wsdl");
- QName serviceName = new QName(targetNS, "DescriptorService");
-
- Service service = Service.create(wsdlURL, serviceName);
- DescriptorEndpoint port =
(DescriptorEndpoint)service.getPort(DescriptorEndpoint.class);
-
- Object retObj = port.echo("Hello");
- assertEquals("Hello", retObj);
- }
-}
\ No newline at end of file
Modified:
stack/cxf/trunk/src/test/java/org/jboss/test/ws/jaxws/cxf/descriptor/DescriptorEndpoint.java
===================================================================
---
stack/cxf/trunk/src/test/java/org/jboss/test/ws/jaxws/cxf/descriptor/DescriptorEndpoint.java 2007-12-18
17:45:00 UTC (rev 5354)
+++
stack/cxf/trunk/src/test/java/org/jboss/test/ws/jaxws/cxf/descriptor/DescriptorEndpoint.java 2007-12-18
17:57:50 UTC (rev 5355)
@@ -26,12 +26,6 @@
import javax.jws.WebService;
import javax.jws.soap.SOAPBinding;
-/**
- * Test the CXF WS-descriptorMessaging
- *
- * @author Thomas.Diesler(a)jboss.org
- * @since 12-Dec-2007
- */
@WebService(name = "DescriptorEndpoint", targetNamespace =
"http://org.jboss.ws.jaxws.cxf/descriptor", serviceName =
"DescriptorService")
@SOAPBinding(style = SOAPBinding.Style.RPC)
public interface DescriptorEndpoint
Modified:
stack/cxf/trunk/src/test/java/org/jboss/test/ws/jaxws/cxf/descriptor/DescriptorEndpointImpl.java
===================================================================
---
stack/cxf/trunk/src/test/java/org/jboss/test/ws/jaxws/cxf/descriptor/DescriptorEndpointImpl.java 2007-12-18
17:45:00 UTC (rev 5354)
+++
stack/cxf/trunk/src/test/java/org/jboss/test/ws/jaxws/cxf/descriptor/DescriptorEndpointImpl.java 2007-12-18
17:57:50 UTC (rev 5355)
@@ -27,12 +27,6 @@
import javax.jws.WebService;
import javax.jws.soap.SOAPBinding;
-/**
- * Test the CXF WS-descriptorMessaging
- *
- * @author Thomas.Diesler(a)jboss.org
- * @since 12-Dec-2007
- */
@WebService(name = "DescriptorEndpoint", targetNamespace =
"http://org.jboss.ws.jaxws.cxf/descriptor", serviceName =
"DescriptorService")
@SOAPBinding(style = SOAPBinding.Style.RPC)
public class DescriptorEndpointImpl
Copied:
stack/cxf/trunk/src/test/java/org/jboss/test/ws/jaxws/cxf/descriptor/DescriptorJSETestCase.java
(from rev 5343,
stack/cxf/trunk/src/test/java/org/jboss/test/ws/jaxws/cxf/descriptor/DescriptorCXFJSETestCase.java)
===================================================================
---
stack/cxf/trunk/src/test/java/org/jboss/test/ws/jaxws/cxf/descriptor/DescriptorJSETestCase.java
(rev 0)
+++
stack/cxf/trunk/src/test/java/org/jboss/test/ws/jaxws/cxf/descriptor/DescriptorJSETestCase.java 2007-12-18
17:57:50 UTC (rev 5355)
@@ -0,0 +1,61 @@
+/*
+ * 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.cxf.descriptor;
+
+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;
+
+/**
+ * Test a CXF endpoint with provided jbossws-cxf.xml
+ *
+ * @author Thomas.Diesler(a)jboss.org
+ * @since 12-Dec-2007
+ */
+public class DescriptorJSETestCase extends JBossWSTest
+{
+ private String endpointURL = "http://" + getServerHost() +
":8080/jaxws-cxf-descriptor/TestService";
+ private String targetNS = "http://org.jboss.ws.jaxws.cxf/descriptor";
+
+ public static Test suite()
+ {
+ return new JBossWSTestSetup(DescriptorJSETestCase.class,
"jaxws-cxf-descriptor.war");
+ }
+
+ public void testLegalAccess() throws Exception
+ {
+ URL wsdlURL = new URL(endpointURL + "?wsdl");
+ QName serviceName = new QName(targetNS, "DescriptorService");
+
+ Service service = Service.create(wsdlURL, serviceName);
+ DescriptorEndpoint port =
(DescriptorEndpoint)service.getPort(DescriptorEndpoint.class);
+
+ Object retObj = port.echo("Hello");
+ assertEquals("Hello", retObj);
+ }
+}
\ No newline at end of file
Added:
stack/cxf/trunk/src/test/java/org/jboss/test/ws/jaxws/cxf/logging/JDKLoggingTestCase.java
===================================================================
---
stack/cxf/trunk/src/test/java/org/jboss/test/ws/jaxws/cxf/logging/JDKLoggingTestCase.java
(rev 0)
+++
stack/cxf/trunk/src/test/java/org/jboss/test/ws/jaxws/cxf/logging/JDKLoggingTestCase.java 2007-12-18
17:57:50 UTC (rev 5355)
@@ -0,0 +1,59 @@
+/*
+ * 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.cxf.logging;
+
+import java.util.logging.Handler;
+import java.util.logging.Logger;
+
+import org.jboss.wsf.common.log.JBossLogHandler;
+import org.jboss.wsf.test.JBossWSTest;
+
+/**
+ * Test redirection of JDK logging on the client side
+ *
+ * @author Thomas.Diesler(a)jboss.org
+ * @since 18-Dec-2007
+ */
+public class JDKLoggingTestCase extends JBossWSTest
+{
+ public void testLogging() throws Exception
+ {
+ Logger log = Logger.getLogger(JDKLoggingTestCase.class.getName());
+ assertHandlers(log);
+
+ log = Logger.getLogger(JDKLoggingTestCase.class.getName());
+ assertHandlers(log);
+
+ log.info("test message");
+ }
+
+ private void assertHandlers(Logger log)
+ {
+ int found = 0;
+ for (Handler handler : log.getHandlers())
+ {
+ if (handler instanceof JBossLogHandler)
+ found++;
+ }
+ assertEquals("Expected one jboss handler", 1, found);
+ }
+}
\ No newline at end of file
Property changes on:
stack/cxf/trunk/src/test/java/org/jboss/test/ws/jaxws/cxf/logging/JDKLoggingTestCase.java
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Modified:
stack/cxf/trunk/src/test/java/org/jboss/test/ws/jaxws/cxf/reliable/RMEndpoint.java
===================================================================
---
stack/cxf/trunk/src/test/java/org/jboss/test/ws/jaxws/cxf/reliable/RMEndpoint.java 2007-12-18
17:45:00 UTC (rev 5354)
+++
stack/cxf/trunk/src/test/java/org/jboss/test/ws/jaxws/cxf/reliable/RMEndpoint.java 2007-12-18
17:57:50 UTC (rev 5355)
@@ -26,12 +26,6 @@
import javax.jws.WebService;
import javax.jws.soap.SOAPBinding;
-/**
- * Test the CXF WS-ReliableMessaging
- *
- * @author Thomas.Diesler(a)jboss.org
- * @since 12-Dec-2007
- */
@WebService(name = "RMEndpoint", targetNamespace =
"http://org.jboss.ws.jaxws.cxf/reliable", serviceName = "RMService")
@SOAPBinding(style = SOAPBinding.Style.RPC)
public interface RMEndpoint
Modified:
stack/cxf/trunk/src/test/java/org/jboss/test/ws/jaxws/cxf/reliable/RMEndpointImpl.java
===================================================================
---
stack/cxf/trunk/src/test/java/org/jboss/test/ws/jaxws/cxf/reliable/RMEndpointImpl.java 2007-12-18
17:45:00 UTC (rev 5354)
+++
stack/cxf/trunk/src/test/java/org/jboss/test/ws/jaxws/cxf/reliable/RMEndpointImpl.java 2007-12-18
17:57:50 UTC (rev 5355)
@@ -27,12 +27,6 @@
import javax.jws.WebService;
import javax.jws.soap.SOAPBinding;
-/**
- * Test the CXF WS-ReliableMessaging
- *
- * @author Thomas.Diesler(a)jboss.org
- * @since 12-Dec-2007
- */
@WebService(name = "RMEndpoint", targetNamespace =
"http://org.jboss.ws.jaxws.cxf/reliable", serviceName = "RMService")
@SOAPBinding(style = SOAPBinding.Style.RPC)
public class RMEndpointImpl