#NEWLINE# def test_graph_flow_four_tasks_revert_failure( self ) : #NEWLINE# #INDENT# flow = gf . Flow ( 'g-3-nasty' ) . add ( utils . NastyTask ( name = 'task2' , provides = 'b' , requires = [ 'a' ] ) , utils . FailingTask ( name = 'task3' , requires = [ 'b' ] ) , utils . ProgressingTask ( name = 'task1' , provides = 'a' ) ) #NEWLINE# engine = self . _make_engine ( flow ) #NEWLINE# self . assertFailuresRegexp ( RuntimeError , '^Gotcha' , engine . run ) #NEWLINE# self . assertEqual ( states . FAILURE , engine . storage . get_flow_state ( ) )