Cypress Image Diff Documentation
  • Migrate from v1 to v2
  • Getting started
    • Cypress integration
      • Typescript
      • Javascript
      • Browserstack
      • Cypress < v10
    • cy.compareSnapshot command
    • Custom config file
      • ROOT_DIR
      • FAILURE_THRESHOLD
      • RETRY_OPTIONS
      • FAIL_ON_MISSING_BASELINE
      • COMPARISON_OPTIONS
      • JSON_REPORT
      • CYPRESS_SCREENSHOT_OPTIONS
      • REPORT_DIR
      • SCREENSHOTS_DIR
      • NAME_TEMPLATE
    • Reporting
      • JSON report
      • Cypress Image Diff HTML Report
      • Legacy HTML Report
    • Client options
    • Running tests
    • Contributing
    • Publishing
Powered by GitBook
On this page
  1. Getting started

Cypress integration

Integration with Cypress

PreviousGetting startedNextTypescript

Last updated 1 year ago

Follow the steps below to have access to the comparison command so you can build visual regression tests

Setup

Install Cypress:

npm i -D cypress

Install the core package and the HTML report:

npm i -D cypress-image-diff-js cypress-image-diff-html-report

Then initialise Cypress if you don't have a project:

npx cypress open

Finally follow a suitable option for you below:

Once the above is complete, you will be all set to !

If you have any struggles with integration, please refer to .

Typescript
Javascript
Cypress < v10
these examples
write a test