This is an automated email from the ASF dual-hosted git repository. davsclaus pushed a commit to branch main in repository https://gitbox.apache.org/repos/asf/camel.git
The following commit(s) were added to refs/heads/main by this push: new 20025017eef Flaky test 20025017eef is described below commit 20025017eef474e1782de7907b385d26636d7958 Author: Claus Ibsen <claus.ib...@gmail.com> AuthorDate: Thu Feb 27 07:09:14 2025 +0100 Flaky test --- .../apache/camel/component/file/FileConsumerCustomSchedulerTest.java | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/core/camel-core/src/test/java/org/apache/camel/component/file/FileConsumerCustomSchedulerTest.java b/core/camel-core/src/test/java/org/apache/camel/component/file/FileConsumerCustomSchedulerTest.java index 6449ec7cda4..9f20d342351 100644 --- a/core/camel-core/src/test/java/org/apache/camel/component/file/FileConsumerCustomSchedulerTest.java +++ b/core/camel-core/src/test/java/org/apache/camel/component/file/FileConsumerCustomSchedulerTest.java @@ -30,6 +30,7 @@ import org.apache.camel.spi.ScheduledPollConsumerScheduler; import org.junit.jupiter.api.Test; import static org.junit.jupiter.api.Assertions.assertEquals; +import static org.junit.jupiter.api.Assertions.assertTrue; public class FileConsumerCustomSchedulerTest extends ContextTestSupport { @@ -53,8 +54,8 @@ public class FileConsumerCustomSchedulerTest extends ContextTestSupport { assertMockEndpointsSatisfied(); // the scheduler is only run once, and we can configure its properties - // (camel run the scheduler once during startup so the value is +1) - assertEquals(2, scheduler.getCounter()); + // (camel may run the scheduler once during startup so the value is +1) + assertTrue(scheduler.getCounter() <= 2); assertEquals("bar", scheduler.getFoo()); }