gnodet opened a new pull request, #24447:
URL: https://github.com/apache/camel/pull/24447

   ## Summary
   
   _Claude Code on behalf of Guillaume Nodet_
   
   Replace `Thread.sleep(100)` calls with 
[Awaitility](https://github.com/awaitility/awaitility) 
`await().atMost().untilAsserted()` in all 7 affected camel-syslog test classes:
   
   - `AutomatedConversionTest`
   - `MinaDataFormatTest`
   - `SyslogSpringMinaTest`
   - `NettyDataFormatTest`
   - `NettyManyUDPMessagesTest`
   - `MinaManyUDPMessagesTest`
   - `SyslogSpringNettyTest`
   
   This eliminates non-deterministic timing dependencies and makes the tests 
more robust by waiting for the mock endpoints to be satisfied rather than 
relying on fixed-time delays.
   
   ### Changes
   
   - Added Awaitility test dependency to `camel-syslog` `pom.xml`
   - Replaced `Thread.sleep(100)` with `await().atMost(N, 
TimeUnit.SECONDS).untilAsserted(() -> MockEndpoint.assertIsSatisfied(context))` 
in all affected test methods
   - Used 5-second timeout for single-message tests and 20-second timeout for 
many-message tests (100 messages)
   - Removed `InterruptedException` from method signatures where it was only 
needed for `Thread.sleep`
   
   All 13 tests in the module pass locally.
   
   ## Test plan
   
   - [x] All camel-syslog tests pass locally (`mvn test -pl 
components/camel-syslog` — 13 tests, 0 failures)
   - [x] Code formatting verified (`mvn formatter:format impsort:sort` — no 
changes needed)
   - [ ] CI pipeline passes


-- 
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]

Reply via email to