Ejemplo n.º 1
0
    def setup(self):
        wsgi_app = None

        x = sys.stdout  # Quixote mangles sys.stdout; save.
        try:
            publisher = create_publisher()
            wsgi_app = quixote.get_wsgi_app()
        finally:
            sys.stdout = x  # restore.

        twill.add_wsgi_intercept('localhost', 80, lambda: wsgi_app, '/qx_test')
Ejemplo n.º 2
0
    def setup(self):
        wsgi_app = None

        x = sys.stdout  # Quixote mangles sys.stdout; save.
        try:
            publisher = create_publisher()
            wsgi_app = quixote.get_wsgi_app()
        finally:
            sys.stdout = x  # restore.

        twill.add_wsgi_intercept("localhost", 80, lambda: wsgi_app, "/qx_test")
Ejemplo n.º 3
0
import quixote, qx_testserver
from wsgiref.simple_server import make_server

qx_testserver.create_publisher()
wsgi_app = quixote.get_wsgi_app()

httpd = make_server('', 8000, wsgi_app)
httpd.serve_forever()