mirror of https://github.com/morpheus65535/bazarr
15 lines
362 B
Python
15 lines
362 B
Python
|
import time
|
||
|
|
||
|
def app(environ, start_response): # pragma: no cover
|
||
|
if environ['PATH_INFO'] == '/sleepy':
|
||
|
time.sleep(2)
|
||
|
body = b'sleepy returned'
|
||
|
else:
|
||
|
body = b'notsleepy returned'
|
||
|
cl = str(len(body))
|
||
|
start_response(
|
||
|
'200 OK',
|
||
|
[('Content-Length', cl), ('Content-Type', 'text/plain')]
|
||
|
)
|
||
|
return [body]
|