jest-websocket-mock icon indicating copy to clipboard operation
jest-websocket-mock copied to clipboard

Is there a way to simulate a lost connection?

Open ElectricCoffee opened this issue 6 months ago • 1 comments

I can see that the library supports close and error, one of which gracefully shuts down the connection, and the other which sends an error message; but I want to simulate the connection abruptly and ungracefully being lost (running out of data, losing wifi, ethernet unplugged, etc). How would I go about doing that?

ElectricCoffee avatar Jan 05 '24 12:01 ElectricCoffee