MCPcopy Index your code
hub / github.com/python-websockets/websockets / test_client_sends_ping

Method test_client_sends_ping

tests/test_protocol.py:1060–1064  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

1058 """
1059
1060 def test_client_sends_ping(self):
1061 client = Protocol(CLIENT)
1062 with patch("secrets.token_bytes", return_value=b"\x00\x44\x88\xcc"):
1063 client.send_ping(b"")
1064 self.assertEqual(client.data_to_send(), [b"\x89\x80\x00\x44\x88\xcc"])
1065
1066 def test_server_sends_ping(self):
1067 server = Protocol(SERVER)

Callers

nothing calls this directly

Calls 3

send_pingMethod · 0.95
data_to_sendMethod · 0.95
ProtocolClass · 0.50

Tested by

no test coverage detected