Snapvisor Docs

Parallel testing

Split a screenshot suite across machines and upload each shard as a batch. Learn Snapvisor's automatic and manual parallel finalize modes.

Large suites run faster when they are sharded across machines. Snapvisor groups the shards into one build so review stays a single, coherent step.

How batching works

Each parallel shard uploads its screenshots as a batch tagged with a shared nonce so Snapvisor knows they belong to the same build. The build tracks how many batches it expects (total) against how many it has received. Once every batch lands, the build finalizes and the comparison runs across all shards at once.

Modes

There are two ways a parallel build knows it is complete:

  • Automatic — you tell Snapvisor the total number of shards up front. The build waits until it has received that many batches, then finalizes on its own. If the last batch never arrives, the build aborts after a timeout.
  • Manual — you don't know the shard count ahead of time, so the build stays open until you run an explicit finalize command. If finalize never runs, the build expires.
# after every shard has uploaded its batch, close the build
npx @snapvisor/cli finalize

In manual mode a build that never receives its finalize command will expire while waiting — wire snapvisor finalize into a step that always runs after your shards complete.

Next steps

Parallel builds behave like any other build once finalized — they diff against the same baseline and post a single check to your pull request. Combine with summary checks to require the whole run before merge.

On this page