None of this works, this just imports the old code, leaving behind those parts not deemed immediately relevant.
25 lines
507 B
Python
25 lines
507 B
Python
"""
|
|
A simple WSGI application for testing.
|
|
"""
|
|
|
|
_app_was_hit = False
|
|
|
|
def success():
|
|
return _app_was_hit
|
|
|
|
def simple_app(environ, start_response):
|
|
"""Simplest possible application object"""
|
|
status = '200 OK'
|
|
response_headers = [('Content-type','text/plain')]
|
|
start_response(status, response_headers)
|
|
|
|
global _app_was_hit
|
|
_app_was_hit = True
|
|
|
|
return ['WSGI intercept successful!\n']
|
|
|
|
def create_fn():
|
|
global _app_was_hit
|
|
_app_was_hit = False
|
|
return simple_app
|