mirror of
https://github.com/oven-sh/bun
synced 2026-02-02 15:08:46 +00:00
18 lines
436 B
Plaintext
18 lines
436 B
Plaintext
---
|
|
title: Set a per-test timeout with the Bun test runner
|
|
sidebarTitle: Test timeout
|
|
mode: center
|
|
---
|
|
|
|
Use the `--timeout` flag to set a timeout for each test in milliseconds. If any test exceeds this timeout, it will be marked as failed.
|
|
|
|
The default timeout is `5000` (5 seconds).
|
|
|
|
```sh terminal icon="terminal"
|
|
bun test --timeout 3000 # 3 seconds
|
|
```
|
|
|
|
---
|
|
|
|
See [Docs > Test runner](/test) for complete documentation of `bun test`.
|