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

Method tearDown

Lib/test/test_logging.py:1887–1896  ·  view source on GitHub ↗

Shutdown the TCP server.

(self)

Source from the content-addressed store, hash-verified

1885 self.handled = threading.Semaphore(0)
1886
1887 def tearDown(self):
1888 """Shutdown the TCP server."""
1889 try:
1890 if self.sock_hdlr:
1891 self.root_logger.removeHandler(self.sock_hdlr)
1892 self.sock_hdlr.close()
1893 if self.server:
1894 self.server.stop()
1895 finally:
1896 BaseTest.tearDown(self)
1897
1898 def handle_socket(self, request):
1899 conn = request.connection

Callers

nothing calls this directly

Calls 4

removeHandlerMethod · 0.80
closeMethod · 0.45
stopMethod · 0.45
tearDownMethod · 0.45

Tested by

no test coverage detected