Skip to content

Instantly share code, notes, and snippets.

@tochman
Created April 21, 2021 09:16
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save tochman/fb2c98b7b1c4d387e7edc99ad84fbef3 to your computer and use it in GitHub Desktop.
Save tochman/fb2c98b7b1c4d387e7edc99ad84fbef3 to your computer and use it in GitHub Desktop.
cy.get("iframe[id=the-id-or-class-or-name]").then(iframe => {
const body = iframe.contents().find('body')
cy.wrap(body)
.find('[data-cy=whatever]')
})
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment