Skip to content

tests: fix flaky TestLogs since/until 1s subtests#4772

Open
AkihiroSuda wants to merge 1 commit intocontainerd:mainfrom
AkihiroSuda:fix-TestLogs
Open

tests: fix flaky TestLogs since/until 1s subtests#4772
AkihiroSuda wants to merge 1 commit intocontainerd:mainfrom
AkihiroSuda:fix-TestLogs

Conversation

@AkihiroSuda
Copy link
Member

The since_1s and until_1s subtests raced against wall clock: if the container finished within 1 second before the command ran, both tests produced wrong results.

Add a 2-second Setup sleep so the container logs are always >1s old by the time the timed-filter commands execute.

NOTE: used Claude Code

The `since_1s` and `until_1s` subtests raced against wall clock: if
the container finished within 1 second before the command ran, both
tests produced wrong results.

Add a 2-second Setup sleep so the container logs are always >1s old
by the time the timed-filter commands execute.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Signed-off-by: Akihiro Suda <akihiro.suda.cz@hco.ntt.co.jp>
@AkihiroSuda AkihiroSuda added this to the v2.3.0 milestone Mar 5, 2026
Copy link
Member

@haytok haytok left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, Thanks!

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

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants