Testing a WebSocket that could hang open for hours

from blog ntietz.com blog, | ↗ original
I recently ran into a bug in some Go code that no one had touched in a few years. The code in question was not particularly complicated, and had been reviewed by multiple people. It included a timeout, and is straightforward: allow a Websocket connection to test that the client can open those successfully, and then close it. The weird thing is...