MCPcopy Index your code
hub / github.com/python/cpython / test_private_init

Method test_private_init

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

Source from the content-addressed store, hash-verified

446 support.check_disallow_instantiation(self, _ssl.Certificate)
447
448 def test_private_init(self):
449 with self.assertRaisesRegex(TypeError, "public constructor"):
450 with socket.socket() as s:
451 ssl.SSLSocket(s)
452
453 def test_str_for_enums(self):
454 # Make sure that the PROTOCOL_* constants have enum-like string

Callers

nothing calls this directly

Calls 2

assertRaisesRegexMethod · 0.80
socketMethod · 0.80

Tested by

no test coverage detected