Prevent connection "freezes" in WebSockets

- A healthy socket can become corrupted after a JSON serialization error
- If the socket isn't then closed by the server, the client will miss  all
  subsequent messages including keep-alives causing the connection
  to freeze until it times out.
- By closing the socket on the server, the client will reconnect immediately

#2800
Test ensuring the server closes WebSockets on serialization failure

- Only applies to Hub return values which aren't pre-serialized on the bus

#2800