MCPcopy Index your code
hub / github.com/RustPython/RustPython / test_unknown_channel_binding

Method test_unknown_channel_binding

Lib/test/test_ssl.py:670–678  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

668 server_hostname="some.hostname")
669
670 def test_unknown_channel_binding(self):
671 # should raise ValueError for unknown type
672 s = socket.create_server(('127.0.0.1', 0))
673 c = socket.socket(socket.AF_INET)
674 c.connect(s.getsockname())
675 with test_wrap_socket(c, do_handshake_on_connect=False) as ss:
676 with self.assertRaises(ValueError):
677 ss.get_channel_binding("unknown-type")
678 s.close()
679
680 @unittest.skipUnless("tls-unique" in ssl.CHANNEL_BINDING_TYPES,
681 "'tls-unique' channel binding not available")

Callers

nothing calls this directly

Calls 8

test_wrap_socketFunction · 0.85
socketMethod · 0.80
create_serverMethod · 0.45
connectMethod · 0.45
getsocknameMethod · 0.45
assertRaisesMethod · 0.45
get_channel_bindingMethod · 0.45
closeMethod · 0.45

Tested by

no test coverage detected