def force_type(cls, response, environ = None): if not isinstance(response, BaseResponse): if environ is None: raise TypeError('cannot convert WSGI application into response objects without an environ') response = BaseResponse(*_run_wsgi_app(response, environ)) response.__class__ = cls return response
def force_type(cls, response, environ = None): if not isinstance(response, BaseResponse): if environ is None: raise TypeError('cannot convert WSGI application into response objects without an environ') response = BaseResponse(*_run_wsgi_app(response, environ)) response.__class__ = cls return response
def from_app(cls, app, environ, buffered = False): return cls(*_run_wsgi_app(app, environ, buffered))
def _run_wsgi_app(*args): global _run_wsgi_app from werkzeug.test import run_wsgi_app as _run_wsgi_app return _run_wsgi_app(*args)
def from_app(cls, app, environ, buffered = False): return cls(*_run_wsgi_app(app, environ, buffered))
def _run_wsgi_app(*args): global _run_wsgi_app from werkzeug.test import run_wsgi_app as _run_wsgi_app return _run_wsgi_app(*args)