Testing
Bun Test Runner Deep Dive: Matchers, Snapshots, Mocks, and Watch Mode
Bun ships a built-in test runner (bun:test) that is Jest-compatible by design. It runs TypeScript natively, starts in milliseconds, and covers the full testing surface — matchers, snapshots, mocks, module mocking, and watch mode — without any additional dependencies. Key Takeaways bun:test is Jest-compatible. Most Jest tests migrate with zero