Skip to content

bahmutov/listen-to-custom-event

Repository files navigation

Listen To A Custom Document Event From Cypress Test

The test cypress/integration/spec.js shows how the Cypress test can listen to the custom DOM events sent to the document object. Watch the video Listen To The Application Dispatching Events To The Document.

The spec also shows how the Cypress test can confirm a custom event sent to the ref.current element by the React code. Watch the video Testing DOM Events Sent to ref.current Element By React App and read the blog post Listen To The Application Events From Cypress Tests

About

Cypress example confirming custom event was sent to the document.

Topics

Resources

Stars

Watchers

Forks