#NEWLINE# def test_nasty_revert( self ) : #NEWLINE# #INDENT# flow = lf . Flow ( 'revert' ) . add ( utils . NastyTask ( 'nasty' ) , utils . FailingTask ( name = 'fail' ) ) #NEWLINE# engine = self . _make_engine ( flow ) #NEWLINE# self . assertFailuresRegexp ( RuntimeError , '^Gotcha' , engine . run ) #NEWLINE# fail = engine . storage . get_revert_result ( 'nasty' ) #NEWLINE# self . assertIsNotNone ( fail . check ( RuntimeError ) ) #NEWLINE# exec_failures = engine . storage . get_execute_failures ( ) #NEWLINE# self . assertIn ( 'fail' , exec_failures ) #NEWLINE# rev_failures = engine . storage . get_revert_failures ( ) #NEWLINE# self . assertIn ( 'nasty' , rev_failures )