Skip to content
Reloads Cypress when one of the watched files changes
Branch: master
Clone or download
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
.vscode
cypress feat: allow pattern for files to watch, close #2 Mar 6, 2019
page feat: allow pattern for files to watch, close #2 Mar 6, 2019
.gitignore chore: update description Mar 6, 2019
.npmrc rework deps Mar 6, 2019
README.md chore: add renovate settings, close #1 Mar 6, 2019
circle.yml
cypress.json feat: click on the button to reload tests Mar 6, 2019
package-lock.json chore(deps): update dependency cypress to v3.3.1 May 23, 2019
package.json
plugins.js fix: use working directory Mar 6, 2019
renovate.json chore: add renovate settings, close #1 Mar 6, 2019
support.js fix: better ready assertion message, close #10 Mar 27, 2019

README.md

cypress-watch-and-reload CircleCI renovate-app badge

Reloads Cypress when one of the watched files changes

Use

npm install cypress-watch-and-reload

Add to your cypress/plugins/index.js file

require('cypress-watch-and-reload/plugins')

Add to your cypress/support/index.js file

require('cypress-watch-and-reload/support')

In your cypress.json set wildcard with files to watch. For example

{
  "cypress-watch-and-reload": {
    "watch": "page/*"
  }
}

Every time you change one of the files matching the wildcard, Cypress will reload itself, rerunning the tests.

This package uses chokidar under the hood, see plugins.js

Example

See project cypress-watch-and-reload-example

Details

This plugin opens a WebSocket connection from Cypress to its Node backend. The backend is watching the specified files. Whenever you change a file, Cypress will notice and will reload itself, rerunning tests.

License

MIT license

You can’t perform that action at this time.