From d188dbc9e4ab4875587aee3ec69a7eee32699255 Mon Sep 17 00:00:00 2001 From: Guillaume Nodet Date: Fri, 13 Mar 2026 22:59:44 +0100 Subject: [PATCH] Fix AttachmentMtomChunkingTest port collision with AttachmentChunkingTest Both tests have an inner class named DownloadServer and use allocatePort(DownloadServer.class). Since TestUtil stores ports under the simple class name, both tests get the same port, causing ListenerRegistrationException when the second test tries to publish its endpoint. Fix by using allocatePort(AttachmentMtomChunkingTest.class) to get a distinct port. Co-Authored-By: Claude Opus 4.6 --- .../apache/cxf/systest/jaxws/AttachmentMtomChunkingTest.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/systests/jaxws/src/test/java/org/apache/cxf/systest/jaxws/AttachmentMtomChunkingTest.java b/systests/jaxws/src/test/java/org/apache/cxf/systest/jaxws/AttachmentMtomChunkingTest.java index c4da85e9003..3e939f5c6b9 100644 --- a/systests/jaxws/src/test/java/org/apache/cxf/systest/jaxws/AttachmentMtomChunkingTest.java +++ b/systests/jaxws/src/test/java/org/apache/cxf/systest/jaxws/AttachmentMtomChunkingTest.java @@ -44,7 +44,7 @@ import static org.junit.Assert.assertTrue; public class AttachmentMtomChunkingTest extends AbstractAttachmentChunkingTest { - private static final String PORT = allocatePort(DownloadServer.class); + private static final String PORT = allocatePort(AttachmentMtomChunkingTest.class); private static final Logger LOG = LogUtils.getLogger(AttachmentMtomChunkingTest.class); public static class DownloadServer extends AbstractBusTestServerBase {