diff --git a/dropwizard-jaxws-example/src/main/java/com/roskart/dropwizard/jaxws/example/ws/WsdlFirstServiceHandler.java b/dropwizard-jaxws-example/src/main/java/com/roskart/dropwizard/jaxws/example/ws/WsdlFirstServiceHandler.java index c4979b8..f2ac374 100644 --- a/dropwizard-jaxws-example/src/main/java/com/roskart/dropwizard/jaxws/example/ws/WsdlFirstServiceHandler.java +++ b/dropwizard-jaxws-example/src/main/java/com/roskart/dropwizard/jaxws/example/ws/WsdlFirstServiceHandler.java @@ -6,8 +6,9 @@ /** * Jakarta XML Web Services server handler when WsdlFirstService is invoked. - * - * See + *

+ * See the {@code wsdlfirstservice-handlerchain.xml} configuration file, which + * is where this class is defined to be a handler. */ public class WsdlFirstServiceHandler extends SimpleLoggingSoapHandler { diff --git a/dropwizard-jaxws-example/src/test/java/com/roskart/dropwizard/jaxws/example/resources/WsdlFirstClientHandlerTest.java b/dropwizard-jaxws-example/src/test/java/com/roskart/dropwizard/jaxws/example/resources/WsdlFirstClientHandlerTest.java new file mode 100644 index 0000000..8d90216 --- /dev/null +++ b/dropwizard-jaxws-example/src/test/java/com/roskart/dropwizard/jaxws/example/resources/WsdlFirstClientHandlerTest.java @@ -0,0 +1,24 @@ +package com.roskart.dropwizard.jaxws.example.resources; + +import static org.assertj.core.api.Assertions.assertThat; +import static org.mockito.Mockito.mock; + +import jakarta.xml.ws.handler.soap.SOAPMessageContext; +import org.junit.jupiter.api.BeforeEach; +import org.junit.jupiter.api.Test; + +class WsdlFirstClientHandlerTest { + + private SOAPMessageContext messageContext; + + @BeforeEach + void setUp() { + messageContext = mock(SOAPMessageContext.class); + } + + @Test + void shouldCreateWithName() { + var handler = new WsdlFirstClientHandler(); + assertThat(handler.handleMessage(messageContext)).isTrue(); + } +} diff --git a/dropwizard-jaxws-example/src/test/java/com/roskart/dropwizard/jaxws/example/ws/WsdlFirstServiceHandlerTest.java b/dropwizard-jaxws-example/src/test/java/com/roskart/dropwizard/jaxws/example/ws/WsdlFirstServiceHandlerTest.java new file mode 100644 index 0000000..c020014 --- /dev/null +++ b/dropwizard-jaxws-example/src/test/java/com/roskart/dropwizard/jaxws/example/ws/WsdlFirstServiceHandlerTest.java @@ -0,0 +1,24 @@ +package com.roskart.dropwizard.jaxws.example.ws; + +import static org.assertj.core.api.Assertions.assertThat; +import static org.mockito.Mockito.mock; + +import jakarta.xml.ws.handler.soap.SOAPMessageContext; +import org.junit.jupiter.api.BeforeEach; +import org.junit.jupiter.api.Test; + +class WsdlFirstServiceHandlerTest { + + private SOAPMessageContext messageContext; + + @BeforeEach + void setUp() { + messageContext = mock(SOAPMessageContext.class); + } + + @Test + void shouldCreateWithName() { + var handler = new WsdlFirstServiceHandler(); + assertThat(handler.handleMessage(messageContext)).isTrue(); + } +} diff --git a/dropwizard-jaxws-example/src/test/resources/.keep b/dropwizard-jaxws-example/src/test/resources/.keep new file mode 100644 index 0000000..e69de29 diff --git a/dropwizard-jaxws/src/main/resources/.keep b/dropwizard-jaxws/src/main/resources/.keep new file mode 100644 index 0000000..e69de29