MCPcopy Create free account
hub / github.com/EasyIME/PIME / setUp

Method setUp

python/python3/tornado/test/httpserver_test.py:725–734  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

723 """
724
725 def setUp(self):
726 super().setUp()
727 self.tmpdir = tempfile.mkdtemp()
728 self.sockfile = os.path.join(self.tmpdir, "test.sock")
729 sock = netutil.bind_unix_socket(self.sockfile)
730 app = Application([("/hello", HelloWorldRequestHandler)])
731 self.server = HTTPServer(app)
732 self.server.add_socket(sock)
733 self.stream = IOStream(socket.socket(socket.AF_UNIX))
734 self.io_loop.run_sync(lambda: self.stream.connect(self.sockfile))
735
736 def tearDown(self):
737 self.stream.close()

Callers

nothing calls this directly

Calls 8

ApplicationClass · 0.90
HTTPServerClass · 0.90
IOStreamClass · 0.90
joinMethod · 0.80
add_socketMethod · 0.80
run_syncMethod · 0.80
setUpMethod · 0.45
connectMethod · 0.45

Tested by

no test coverage detected