This is a complete testing setup for Cloudflare Workers using Vitest 2.1.8 and the official @cloudflare/vitest-pool-workers 0.7.2. It covers the full workflow: configuring the test pool, accessing real bindings through cloudflare:test (D1, KV, R2, Durable Objects, Queues, AI), handling execution contexts properly with waitOnExecutionContext, and setting up isolated storage per test. The critical rules section is worth your time because it shows the exact mistakes people make, like forgetting to wait on context or trying to mock env manually instead of using the provided module. Updated for the January 2025 breaking changes in Miniflare v3, so you won't be chasing outdated syntax.
npx skills add https://github.com/secondsky/claude-skills --skill cloudflare-workers-testing