#NEWLINE# def test_process_config( request_app = test_request_config ) : #NEWLINE# #INDENT# try : #NEWLINE# #INDENT# process_config = { #NEWLINE# #INDENT# test_key : 'bar' , #NEWLINE# 'process_var' : 'foo' , #NEWLINE# #UNINDENT# } #NEWLINE# CONFIG . push_process_config ( request_app ) #NEWLINE# assert ( CONFIG [ test_key ] == 'bar' ) #NEWLINE# assert ( CONFIG [ 'process_var' ] == 'foo' ) #NEWLINE# request_app ( ) #NEWLINE# assert ( CONFIG [ test_key ] == 'bar' ) #NEWLINE# assert ( CONFIG [ 'process_var' ] == 'foo' ) #NEWLINE# CONFIG . pop_process_config ( ) #NEWLINE# assert_raises ( AttributeError , ( lambda : ( 'process_var' not in CONFIG ) ) ) #NEWLINE# assert_raises ( IndexError , CONFIG . pop_process_config ) #NEWLINE# #UNINDENT# finally : #NEWLINE# #INDENT# reset_config ( )