Skip to main content

Set a per-test timeout with the Bun test runner

还没翻译译自英文(bun.com)本页 4 段都还没译

Use the --timeout flag to set a timeout for each test in milliseconds. Bun marks a test that exceeds this timeout as failed.

The default timeout is 5000 (5 seconds).

bun test --timeout 3000 # 3 seconds

See bun test.

翻訳 © 2026 fanyi.dev · 原文 © 2026 the Bun project (LICENSE.md names no copyright holder) (MIT)