xref: /unit/test/python/atexit/wsgi.py (revision 603:a11b80dedc6b)
1import atexit
2
3def application(environ, start_response):
4    def at_exit():
5        environ['wsgi.errors'].write('At exit called.')
6
7    atexit.register(at_exit)
8
9    start_response('200', [('Content-Length', '0')])
10    return []
11