close

testTimeout

  • Type: number
  • Default: 5_000
  • CLI: --testTimeout=5000

Default timeout of a test in milliseconds. 0 will disable the timeout.

CLI
rstest.config.ts
npx rstest --testTimeout=5000

Rstest determines the test timeout based on the following priority order:

  1. timeout configuration in each test case
  2. Timeout configured in the test file via rstest.setConfig({ testTimeout })
  3. --testTimeout option in CLI
  4. testTimeout option in the configuration file
  5. Default value of 5000 milliseconds