Skip to content
Latchkey

Test Sharding - CI/CD Glossary Definition

Test sharding splits a suite into subsets that run on separate runners in parallel to cut total time.

Test sharding splits a test suite into independent subsets (shards) that run on separate runners in parallel, then combines the results. It cuts wall-clock time for large suites.

GitHub Actions supports sharding through a matrix that passes each job a shard index. Balancing shards by historical runtime avoids one slow shard dominating.

In CI

A strategy.matrix with a shard index and total count is the common pattern; each job runs its slice and uploads results as artifacts for merging.

Related guides

Run this faster and cheaper on Latchkey managed runners. Start free →