Skip to content

Comments

Parallelize integration test suite#424

Merged
ryanfowler merged 1 commit intomainfrom
refactor/parallelize-integration-tests
Feb 13, 2026
Merged

Parallelize integration test suite#424
ryanfowler merged 1 commit intomainfrom
refactor/parallelize-integration-tests

Conversation

@ryanfowler
Copy link
Owner

Summary

  • Add t.Parallel() to all 132 subtests so they run concurrently
  • Eliminate shared mutable state that prevented parallelization:
    • Replace os.Setenv with cmd.Env via new runFetchOpts helper (aws-sigv4, update, session tests)
    • Replace os.Chdir with cmd.Dir via fetchOpts (6 output/remote-name tests)
    • Replace shared tempDir with per-test t.TempDir() (unix socket, mtls, inspect-tls, session)
    • Copy binary for update test to avoid modifying shared fetchPath
    • Use t.Cleanup instead of defer for servers shared by parallel subtests (grpc client streaming, mtls, inspect-tls)

Test plan

  • go test ./... passes
  • go test -race ./integration/... passes (no data races)
  • gofmt -l . reports no formatting issues

Add t.Parallel() to all 132 subtests so they run concurrently.
Eliminate shared mutable state that prevented parallelization:

- Replace os.Setenv with cmd.Env via new runFetchOpts helper
- Replace os.Chdir with cmd.Dir via fetchOpts
- Replace shared tempDir with per-test t.TempDir()
- Copy binary for update test to avoid modifying shared fetchPath
- Use t.Cleanup instead of defer for servers shared by parallel subtests
@ryanfowler ryanfowler merged commit 1a798e7 into main Feb 13, 2026
10 checks passed
@ryanfowler ryanfowler deleted the refactor/parallelize-integration-tests branch February 13, 2026 00:41
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