I have a webapp that the majority of its functionality is based on websockets events.
For example:
upon connecting to the websockets server, the server will send the event
{ type: 'server-init', client_id: '1' }
When the client receives that message, it will display the client id on the page.
I would like to test this case using puppeteer - if possible - but I haven't found a reasonable way to mock websockets while using puppeteer.
Any ideas? Is it possible?
Aucun commentaire:
Enregistrer un commentaire