Control The Application Through PubSub From Cypress

1 · Gleb Bahmutov · Aug. 6, 2021, 7:09 p.m.
A user has recently asked me about using Cypress tests not delivering events into the application. The application is using pubsub-js from the "Publisher" component to publish events. Other components, like the "Subscriber" component can subscribe to PubSub events and then updates the page UI.Publisher12345678<button type="button" @click.prevent="notifyNavbar" data-cy="publisherbutton">import PubSub from "pubsub-js";function notifyNavbar() { console.log("Sending Notification"); PubSub.publish(...