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

Method test_close_immediately

Lib/test/test_socketserver.py:275–280  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

273 s.server_close()
274
275 def test_close_immediately(self):
276 class MyServer(socketserver.ThreadingMixIn, socketserver.TCPServer):
277 pass
278
279 server = MyServer((HOST, 0), lambda: None)
280 server.server_close()
281
282 def test_tcpserver_bind_leak(self):
283 # Issue #22435: the server socket wouldn't be closed if bind()/listen()

Callers

nothing calls this directly

Calls 2

MyServerClass · 0.70
server_closeMethod · 0.45

Tested by

no test coverage detected