squakez commented on code in PR #20223:
URL: https://github.com/apache/camel/pull/20223#discussion_r2588123861
##########
components/camel-test/camel-test-junit6/src/test/java/org/apache/camel/test/junit6/patterns/FilterCreateCamelContextPerClassTest.java:
##########
@@ -33,7 +33,9 @@ public class FilterCreateCamelContextPerClassTest extends
CamelTestSupport {
public void testSendMatchingMessage() throws Exception {
String expectedBody = "<matched/>";
- getMockEndpoint("mock:result").expectedBodiesReceived(expectedBody);
+ MockEndpoint me = getMockEndpoint("mock:result");
+ me.expectedBodiesReceived(expectedBody);
+ me.reset();
Review Comment:
The problem here is that the context is shared. Therefore, when the second
test executes it still finds the exchanges done in the previous test. So, we
either reset or we should create a new context.
--
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: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]