#NEWLINE# def test_can_get_custom_error_messages_out( prot ) : #NEWLINE# #INDENT# request = prot . create_request ( 'foo' ) #NEWLINE# custom_msg = 'join the army, they said. see the world, they said.' #NEWLINE# e = Exception ( custom_msg ) #NEWLINE# response = request . error_respond ( e ) #NEWLINE# data = json . loads ( response . serialize ( ) ) #NEWLINE# assert ( data [ 'error' ] [ 'message' ] == custom_msg )