JiriOndrusek commented on code in PR #4721: URL: https://github.com/apache/camel-quarkus/pull/4721#discussion_r1154098890
########## integration-test-groups/cxf-soap/cxf-soap-ws-rm/src/test/java/org/apache/camel/quarkus/component/cxf/soap/wsrm/it/CxfSoapWsrmTest.java: ########## @@ -0,0 +1,89 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package org.apache.camel.quarkus.component.cxf.soap.wsrm.it; + +import java.util.concurrent.TimeUnit; + +import io.quarkus.test.junit.DisabledOnIntegrationTest; +import io.quarkus.test.junit.QuarkusTest; +import io.quarkus.test.junit.QuarkusTestProfile; +import io.quarkus.test.junit.TestProfile; +import io.restassured.RestAssured; +import org.awaitility.Awaitility; +import org.junit.jupiter.api.Test; + +import static org.hamcrest.Matchers.equalTo; +import static org.hamcrest.Matchers.is; +import static org.hamcrest.Matchers.not; + +@QuarkusTest +@TestProfile(CxfSoapWsrmTest.class) +public class CxfSoapWsrmTest implements QuarkusTestProfile { + + // Test is ported from WSRMTest in Camel-spring-boot/components-starter/camel-cxf-soap-starter + @Test + @DisabledOnIntegrationTest // see https://github.com/apache/camel-quarkus/issues/4689 + public void testWSRM() { + RestAssured.given() + .body("wsrm1") + .post("/cxf-soap/wsrm") + .then() + .statusCode(201) + .body(equalTo("Hello wsrm1!")); + + //second message will be lost (in the first attempt) + RestAssured.given() + .body("wsrm2") + .post("/cxf-soap/wsrm") + .then() + .statusCode(201) + .body(equalTo("Hello wsrm2!")); + } Review Comment: You idea sounds good. I solved the same by running the second test method, which verifies that the first message is not delivered without wsrm -> your approach is more straightforward and does not need to wait for delivery failure. I'll try it. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: commits-unsubscr...@camel.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org