cypress-io / netlify-plugin-cypress

Runs Cypress end-to-end tests after Netlify builds the site but before it is deployed

Home Page:https://www.cypress.io/blog/2020/03/30/run-cypress-tests-on-netlify-using-a-single-line/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Optionally fail Netlify deployment if Cypress tests fail

aaronransley opened this issue ยท comments

Is your feature request related to a problem? Please describe.
Netlify pushes a deployment to production (if configured to auto-publish) even if Cypress tests fail.

Describe the solution you'd like
I would like the ability to optionally fail the Netlify deployment if any of the configured Cypress tests fail.

Describe alternatives you've considered
I've attempted to use a build command like yarn test && yarn build to gate the deployment against Cypress tests succeeding, but this means I lose out on the benefits of using this dedicated plugin.

Additional context
It appears there might be a quick win with the { utils } helper passed into Netlify plugin build hooks.

๐ŸŽ‰ This issue has been resolved in version 2.2.0 ๐ŸŽ‰

The release is available on:

Your semantic-release bot ๐Ÿ“ฆ๐Ÿš€