def setUpClass(cls): cls.io_loop = ioloop.IOLoop() app = wsgi.WSGIContainer(TestingApp()) cls.http_server, cls.http_port = run_tornado_app( app, cls.io_loop, None, 'http', cls.http_host) app = wsgi.WSGIContainer(TestingApp()) cls.https_server, cls.https_port = run_tornado_app( app, cls.io_loop, cls.https_certs, 'https', cls.http_host) app = web.Application([(r'.*', ProxyHandler)]) cls.proxy_server, cls.proxy_port = run_tornado_app( app, cls.io_loop, None, 'http', cls.proxy_host) cls.server_thread = run_loop_in_thread(cls.io_loop)
def _start_server(cls): cls.io_loop = ioloop.IOLoop() app = wsgi.WSGIContainer(TestingApp()) cls.server, cls.port = run_tornado_app(app, cls.io_loop, cls.certs, cls.scheme, cls.host) cls.server_thread = run_loop_in_thread(cls.io_loop)