class Onyx::HTTP::Spec::WebSocketWrapper

Defined in:


Instance Method Summary

Instance Method Detail

def assert_response(expected, wait : Time::Span | Number = 0.1.seconds) #

Assert the latest socket response after wait. It includes sleep, which allows a websocket handler to process the request.


[View source]
def assert_response(request, *args, **nargs) #

Send the request and then call #assert_response with given arguments.

[View source]
def responses : Array(Slice(UInt8) | String) #

Reponses history.

[View source]
def send(payload) #

Send payload to the #socket.

[View source]
def socket : ::HTTP::WebSocket #

Direct socket accessor, if needed.

[View source]