Return-Path: X-Original-To: archive-asf-public-internal@cust-asf2.ponee.io Delivered-To: archive-asf-public-internal@cust-asf2.ponee.io Received: from cust-asf.ponee.io (cust-asf.ponee.io [163.172.22.183]) by cust-asf2.ponee.io (Postfix) with ESMTP id 98312200B21 for ; Fri, 10 Jun 2016 20:19:04 +0200 (CEST) Received: by cust-asf.ponee.io (Postfix) id 96CF0160A5B; Fri, 10 Jun 2016 18:19:04 +0000 (UTC) Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by cust-asf.ponee.io (Postfix) with SMTP id E68E9160A38 for ; Fri, 10 Jun 2016 20:19:03 +0200 (CEST) Received: (qmail 61037 invoked by uid 500); 10 Jun 2016 18:19:03 -0000 Mailing-List: contact commits-help@cxf.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@cxf.apache.org Delivered-To: mailing list commits@cxf.apache.org Received: (qmail 60910 invoked by uid 99); 10 Jun 2016 18:19:03 -0000 Received: from git1-us-west.apache.org (HELO git1-us-west.apache.org) (140.211.11.23) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 10 Jun 2016 18:19:03 +0000 Received: by git1-us-west.apache.org (ASF Mail Server at git1-us-west.apache.org, from userid 33) id EA9E3DFE61; Fri, 10 Jun 2016 18:19:02 +0000 (UTC) Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit From: dkulp@apache.org To: commits@cxf.apache.org Date: Fri, 10 Jun 2016 18:19:03 -0000 Message-Id: In-Reply-To: References: X-Mailer: ASF-Git Admin Mailer Subject: [2/3] cxf git commit: Fix UDP tests on my mac archived-at: Fri, 10 Jun 2016 18:19:04 -0000 Fix UDP tests on my mac Project: http://git-wip-us.apache.org/repos/asf/cxf/repo Commit: http://git-wip-us.apache.org/repos/asf/cxf/commit/0572061e Tree: http://git-wip-us.apache.org/repos/asf/cxf/tree/0572061e Diff: http://git-wip-us.apache.org/repos/asf/cxf/diff/0572061e Branch: refs/heads/3.1.x-fixes Commit: 0572061edf5ab349dc61e77fbb8d360c7521d111 Parents: 83846d0 Author: Daniel Kulp Authored: Tue Jun 7 13:52:42 2016 -0400 Committer: Daniel Kulp Committed: Fri Jun 10 13:35:29 2016 -0400 ---------------------------------------------------------------------- .../cxf/transport/udp/UDPTransportTest.java | 24 ++++++++++++++++++-- 1 file changed, 22 insertions(+), 2 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/cxf/blob/0572061e/rt/transports/udp/src/test/java/org/apache/cxf/transport/udp/UDPTransportTest.java ---------------------------------------------------------------------- diff --git a/rt/transports/udp/src/test/java/org/apache/cxf/transport/udp/UDPTransportTest.java b/rt/transports/udp/src/test/java/org/apache/cxf/transport/udp/UDPTransportTest.java index fea6ce1..9c0052c 100644 --- a/rt/transports/udp/src/test/java/org/apache/cxf/transport/udp/UDPTransportTest.java +++ b/rt/transports/udp/src/test/java/org/apache/cxf/transport/udp/UDPTransportTest.java @@ -22,12 +22,13 @@ package org.apache.cxf.transport.udp; import java.net.NetworkInterface; import java.util.Enumeration; +import javax.jws.WebService; + import org.apache.cxf.endpoint.Server; import org.apache.cxf.jaxws.JaxWsProxyFactoryBean; import org.apache.cxf.jaxws.JaxWsServerFactoryBean; import org.apache.cxf.testutil.common.AbstractBusClientServerTestBase; import org.apache.hello_world.Greeter; -import org.apache.hello_world.GreeterImpl; import org.junit.AfterClass; import org.junit.BeforeClass; @@ -40,6 +41,23 @@ public class UDPTransportTest extends AbstractBusClientServerTestBase { static final String PORT = allocatePort(UDPTransportTest.class); private static Server server; + @WebService(serviceName = "SOAPService", + endpointInterface = "org.apache.hello_world.Greeter", + targetNamespace = "http://apache.org/hello_world") + static class GreeterImpl implements Greeter { + private String myName = "defaultGreeter"; + GreeterImpl() { + } + public String greetMe(String me) { + return "Hello " + me; + } + public String sayHi() { + return "Bonjour from " + myName; + } + public void pingMe() { + } + } + @BeforeClass public static void setUpBeforeClass() throws Exception { @@ -53,7 +71,9 @@ public class UDPTransportTest extends AbstractBusClientServerTestBase { @AfterClass public static void shutdown() throws Exception { - server.stop(); + if (server != null) { + server.stop(); + } } @Test