diff --git a/integration-test-groups/cxf-soap/cxf-soap-ws-security-client/src/test/java/org/apache/camel/quarkus/component/cxf/soap/wss/client/it/CxfSoapWssClientTest.java b/integration-test-groups/cxf-soap/cxf-soap-ws-security-client/src/test/java/org/apache/camel/quarkus/component/cxf/soap/wss/client/it/CxfSoapWssClientTest.java index e217d84b148b..554f76369c46 100644 --- a/integration-test-groups/cxf-soap/cxf-soap-ws-security-client/src/test/java/org/apache/camel/quarkus/component/cxf/soap/wss/client/it/CxfSoapWssClientTest.java +++ b/integration-test-groups/cxf-soap/cxf-soap-ws-security-client/src/test/java/org/apache/camel/quarkus/component/cxf/soap/wss/client/it/CxfSoapWssClientTest.java @@ -43,7 +43,6 @@ import org.testcontainers.shaded.org.awaitility.Awaitility; import static org.hamcrest.Matchers.equalTo; -import static org.hamcrest.Matchers.is; @QuarkusTest @QuarkusTestResource(CxfWssClientTestResource.class) @@ -116,7 +115,7 @@ public void testWrongClientNotHanging() { //always fails because there is no server implementation createSayHelloWrongClient().sayHelloWrong("Sheldon"); } catch (SOAPFaultException e) { - return "Connection refused".equals(e.getMessage()); + return e.getMessage() != null && e.getMessage().toLowerCase().contains("connection refused"); } //can not happen (client does not work) return false;