- All playbooks
- Slow tests
- Split independent work off the longest job
Split independent work off the longest job
Run independent suites in parallel jobs when the overlap saves more than the repeated setup costs.
Company examples
How Stripe used this technique
Read what Stripe changed and follow the original sources.
Split independent work off the longest job
Stripe iOS split installation and integration tests into separate jobs, keeping all five installation variants together so they share setup. Earlier, it moved one measured slow test class into its own job.
The combined job took about 27 minutes; after the split, installation took about 11 to 12 minutes and integration about 13 minutes, running in parallel, in Stripe’s combined CI runs. Source
- Use it when
- Two independent suites run one after another in the job that holds up the pull request.
- Before applying it
- Each new job repeats setup and may queue. Keep every test variant and simulator version, and keep one stable required check that reports every job’s result.
Company Playbooks
- Read Anthropic’s playbookRun only affected tests
- Read DoorDash’s playbookRun build and test in parallel, sharded across CI agents
- Read Linear’s playbookBenchmark the same job on faster hardware
- Read Mastra’s playbookStarSling runners for the slowest test workflow
- Read OpenAI’s playbookRank CI fixes by the minutes they save
- Read Ramp’s playbookMove a CPU-bound test suite to a faster CPU
- Read Shopify’s playbookLet an agent iterate against one CI metric
- Read Spotify’s playbookBuild arm64 on native arm64 runners
- Read Stripe’s playbookRun only the tests a change can reach
- Read Uber’s playbookBuild the merge-queue speculations most likely to be needed