From 44889ef65d38b10c86f43a1298bdfb99793d2f0b Mon Sep 17 00:00:00 2001 From: Paul Buetow Date: Mon, 23 Feb 2026 22:18:48 +0200 Subject: Use NumCPU*2 as default integration test parallelism --- Magefile.go | 4 ++-- integrationtests/README.md | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/Magefile.go b/Magefile.go index d9ad29e..50d2bea 100644 --- a/Magefile.go +++ b/Magefile.go @@ -278,7 +278,7 @@ func IntegrationTestSerial() error { } // IntegrationTestParallel builds everything and runs integration tests in parallel. -// Set INTEGRATION_PARALLEL to tune `go test -parallel` (default: NumCPU/2, minimum 1). +// Set INTEGRATION_PARALLEL to tune `go test -parallel` (default: NumCPU*2, minimum 1). func IntegrationTestParallel() error { return runIntegrationTests(true) } @@ -323,7 +323,7 @@ func runIntegrationTests(parallel bool) error { func resolveIntegrationParallelism() (int, error) { parallel := strings.TrimSpace(os.Getenv(integrationParallel)) if parallel == "" { - n := runtime.NumCPU() / 2 + n := runtime.NumCPU() * 2 if n < 1 { n = 1 } diff --git a/integrationtests/README.md b/integrationtests/README.md index 601b782..99a3fc0 100644 --- a/integrationtests/README.md +++ b/integrationtests/README.md @@ -16,7 +16,7 @@ mage integrationTest ``` This builds everything (ior, ioworkload) and runs integration tests in parallel. -Default parallelism is half of available CPU cores (minimum `1`). +Default parallelism is `NumCPU * 2` (minimum `1`). Tests automatically skip with `t.Skip` when not running as root. -- cgit v1.2.3