Skip to content

test: simplify sleep-and-wait pairs with synctest.Sleep - #4323

Merged
dgageot merged 1 commit into
mainfrom
test/synctest-sleep
Sep 16, 2026
Merged

dgageot merged 1 commit into
mainfrom
test/synctest-sleep

Conversation

@dgageot

@dgageot dgageot commented Sep 16, 2026

Copy link
Copy Markdown
Member

Replace seven time.Sleep(d); synctest.Wait() pairs with Go 1.27's synctest.Sleep(d), which is documented as exactly equivalent.

  • Simplify five pairs in source-loader tests and one each in streaming and delegation tests.
  • Remove seven unnecessary //nolint:forbidigo suppressions and their fake-time justifications.
  • Preserve durations, leading waits, standalone sleeps, assertions, and timeout-boundary comments. No production-code changes.

Validation

  • CI=true task build and task lint pass (0 lint issues).
  • Affected tests pass 20 times with -race -shuffle=on.
  • With .env.test loaded, go test -p 4 ./... passes when only the two DMR example-loading subtests are skipped.
  • Unfiltered task test fails on TestLoadExamples for dmr.yaml and unload_on_switch.yaml because Docker Model Runner is not running locally. Both failures reproduce with the unchanged base files through a Go overlay.
  • A highly parallel filtered rerun also hit process-start timeout failures in codingharness and evaluation; both passed in the lower-parallelism rerun.

Signed-off-by: David Gageot <david.gageot@docker.com>
Assisted-By: claude-opus-4-5
@dgageot
dgageot requested a review from a team as a code owner September 16, 2026 17:16
@dgageot
dgageot added this pull request to the merge queue Sep 16, 2026
@aheritier aheritier added area/core Core agent runtime, session management area/runtime Runtime engine, agent loop execution, tool dispatch, loop detection kind/test Test-only changes labels Sep 16, 2026
Merged via the queue into main with commit 4f209de Sep 16, 2026
17 checks passed
@dgageot
dgageot deleted the test/synctest-sleep branch September 16, 2026 17:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area/core Core agent runtime, session management area/runtime Runtime engine, agent loop execution, tool dispatch, loop detection kind/test Test-only changes

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants