Skip to content

Instantly share code, notes, and snippets.

@DevanB
Created November 14, 2018 03:23
Show Gist options
  • Save DevanB/d17f0882f754b33bf75fbd8a3d12d973 to your computer and use it in GitHub Desktop.
Save DevanB/d17f0882f754b33bf75fbd8a3d12d973 to your computer and use it in GitHub Desktop.

Debugging Cypress Tests

cy.visit('/')
 .get('something')
 .click()
 .then(subject => {
   debugger;
   return subject;
 })
 ...
if (window.Cypress) {
  // do stuff that only executes in Cypress here
}

Created with 📕TILed

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment