Skip to content

Replace sleep with assert period in file tests#1802

Open
Dolanss wants to merge 1 commit into
apache:mainfrom
Dolanss:test/remove-thread-sleep-file-starter
Open

Replace sleep with assert period in file tests#1802
Dolanss wants to merge 1 commit into
apache:mainfrom
Dolanss:test/remove-thread-sleep-file-starter

Conversation

@Dolanss
Copy link
Copy Markdown
Contributor

@Dolanss Dolanss commented May 30, 2026

This replaces Thread.sleep() with MockEndpoint#setAssertPeriod(...) in two file component tests.

These tests are checking that no exchanges are received during a period of time, so using an assert period makes the intent clearer and avoids relying on sleep-based timing.

Updated tests:

  • FileConsumerIdempotentTest
  • FilerConsumerDoneFileNamePrefixTest

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants