interface PoolOptions {
    forks?: ForksOptions & WorkerContextOptions;
    threads?: ThreadsOptions & WorkerContextOptions;
    vmThreads?: ThreadsOptions & VmOptions;
}

Hierarchy

  • Record<string, unknown>
    • PoolOptions

Properties

forks?: ForksOptions & WorkerContextOptions

Run tests in node:child_process using fork()

Test isolation (when enabled) is done by spawning a new child process for each test file.

threads?: ThreadsOptions & WorkerContextOptions

Run tests in node:worker_threads.

Test isolation (when enabled) is done by spawning a new thread for each test file.

This pool is used by default.

vmThreads?: ThreadsOptions & VmOptions

Run tests in isolated node:vm. Test files are run parallel using node:worker_threads.

This makes tests run faster, but VM module is unstable. Your tests might leak memory.

Generated using TypeDoc