Skip to content

dash, scrape: tests that do not depend on scheduling - #5

Merged
igorrius merged 1 commit into
mainfrom
dash-test-flakes
Oct 28, 2026
Merged

igorrius merged 1 commit into
mainfrom
dash-test-flakes

Conversation

@igorrius

Copy link
Copy Markdown
Owner

Follow-up to #4: TestServe failed on the macOS runner (run).

  • TestServe took the first event of the stream as the data, but a stream opened before the first scrape finishes starts with an empty frame ("scrapes":0), which is intended. It now reads frames until the metrics arrive (5s deadline), and its first scrape is made slow on purpose — that reproduced the CI failure locally and keeps the path tested.
  • TestUserAgent waits for the handler call instead of relying on the 100ms Close grace.
  • TestHandlerHung checks the "busy" error instead of a 10ms time bound.

Tests only. make test and golangci-lint pass; dash, internal/scrape, internal/web pass 30 runs with -race at GOMAXPROCS=1.

🤖 Generated with Claude Code

https://claude.ai/code/session_01US3HyDZUDYV2efX1EkkXgd

TestServe took the first event of the stream as the data, but a stream
opened before the first scrape finishes starts with an empty frame (seen
on the macOS runner). It now reads frames until the metrics arrive, and
its first scrape is made slow on purpose to keep that path tested.
TestUserAgent waits for the handler call instead of the Close grace, and
TestHandlerHung checks the busy error rather than a 10ms bound.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01US3HyDZUDYV2efX1EkkXgd
@igorrius igorrius self-assigned this Oct 28, 2026
@igorrius
igorrius merged commit b9a44e6 into main Oct 28, 2026
5 checks passed
@igorrius
igorrius deleted the dash-test-flakes branch October 28, 2026 20:31
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.

1 participant