Skip to content

Testing

Review the tools available for testing and debugging Workers.

Testing comparison matrix

FeatureVitest Poolunstable_dev()Miniflare's API
Unit testing
Integration testing
Loading Wrangler configuration files
Bindings directly in tests
Isolated per-test storage
Outbound request mocking
Multiple Worker support🚧1
Direct access to Durable Objects
Run Durable Object alarms immediately
List Durable Objects
Testing service Workers

Footnotes

  1. Support for multiple Workers in unstable_dev() relies on wrangler dev's service registry which can be unreliable when running multiple tests in parallel.