Guillaume Nodet created CAMEL-24022:
---------------------------------------
Summary: Fix flaky XsltFromFileExceptionTest
Key: CAMEL-24022
URL: https://issues.apache.org/jira/browse/CAMEL-24022
Project: Camel
Issue Type: Bug
Components: camel-core
Reporter: Guillaume Nodet
The test XsltFromFileExceptionTest is flaky in CI. According to Develocity, it
has 6 failures out of 254 runs in July 2026.
The test consumes files via a file consumer, processes through XSLT, and
asserts mock endpoints. The flakiness is caused by a race condition:
assertMockEndpointsSatisfied() is called before waiting for the file consumer
to process the file via oneExchangeDone.matchesWaitTime(). Under CI load, the
file consumer may not have picked up the file within the default 10-second mock
wait time.
The fix reorders the wait: first wait for the exchange to complete via
oneExchangeDone.matchesWaitTime(), then assert mock expectations.
--
This message was sent by Atlassian Jira
(v8.20.10#820010)