Skip to content

test(relay): run the suite in parallel - #812

Merged
omartelo merged 1 commit into
mainfrom
test/relay-parallel
Oct 17, 2026
Merged

omartelo merged 1 commit into
mainfrom
test/relay-parallel

Conversation

@omartelo

Copy link
Copy Markdown
Collaborator

internal/relay takes 40s on every OS and is the floor of the Linux and macOS backend suites: its tests mostly wait on timers (receipt windows, nudge delays), one after another.

  • 247 of the 248 tests now call t.Parallel() as their first line. Nothing else changes in them.
  • The one left serial sets HOME/USERPROFILE with t.Setenv (insert_test.go). The package holds no other process-wide state: its test-level vars are fixed values and every test builds its own Service.

The risk is timing, since many tests run 40ms windows, so it was stressed: -race -count=30 at GOMAXPROCS=4 and -count=30 -parallel=64 at GOMAXPROCS=2 (starved on purpose), ~7,400 executions each, no failure and no race. Locally at 4 procs: 40s → ~10.5s. go vet clean for linux, windows and darwin.

@omartelo
omartelo merged commit 2a8f2e6 into main Oct 17, 2026
7 checks passed
@omartelo
omartelo deleted the test/relay-parallel branch October 17, 2026 19:10
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