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

Method test_no_extensions

tests/test_server.py:686–695  ·  view source on GitHub ↗

Handshake succeeds without extensions.

(self)

Source from the content-addressed store, hash-verified

684 self.assertIsNone(server.origin)
685
686 def test_no_extensions(self):
687 """Handshake succeeds without extensions."""
688 server = ServerProtocol()
689 request = make_request()
690 response = server.accept(request)
691 server.send_response(response)
692
693 self.assertHandshakeSuccess(server)
694 self.assertNotIn("Sec-WebSocket-Extensions", response.headers)
695 self.assertEqual(server.extensions, [])
696
697 def test_extension(self):
698 """Server enables an extension when the client offers it."""

Callers

nothing calls this directly

Calls 5

acceptMethod · 0.95
send_responseMethod · 0.95
ServerProtocolClass · 0.85
make_requestFunction · 0.85

Tested by

no test coverage detected