WebSocket unit test