jest-watch-suspend
TypeScript icon, indicating that this package has built-in type declarations

1.1.2 • Public • Published

jest-watch-suspend

NPM version NPM downloads

Circle CI Travis CI Codecov Coveralls Status

Greenkeeper Semantic Release

Visual Studio Code Wallaby.js

Pausing/resuming jest watch mode.

Requires jest@23+.

Usage

To use jest-watch-suspend, add it to the watchPlugins section of the Jest configuration:

{
  "jest": {
    "watchPlugins": [
      // default
      "jest-watch-suspend",
      // configure
      [
        "jest-watch-suspend", {
          // override key press
          "key": "s",
          // override prompt
          "prompt": "suspend watch mode",
          // starts in suspend mode
          "suspend-on-start": true
        }
      ]
    ]
  }
}

Use Cases

Suspend on start:

  • (suspended) -> [p] + <filter> | [t] + <filter> -> [s] (resume)

Setup both path and name filter before running tests:

  • [s] (suspend) -> [p] + <filter> -> [t] + <filter> -> [s] (resume)

Change multiple files before running tests:

  • [s] (suspend) -> multiple changes and file saves -> [s] (resume)

Package Sidebar

Install

npm i jest-watch-suspend

Weekly Downloads

3,095

Version

1.1.2

License

MIT

Unpacked Size

9.51 kB

Total Files

9

Last publish

Collaborators

  • unional