#NEWLINE# def test_iter_nodes( self ) : #NEWLINE# #INDENT# task1 = _task ( 'task1' , provides = [ 'a' ] , requires = [ 'c' ] ) #NEWLINE# task2 = _task ( 'task2' , provides = [ 'b' ] , requires = [ 'a' ] ) #NEWLINE# task3 = _task ( 'task3' , provides = [ 'c' ] ) #NEWLINE# f1 = gf . Flow ( 'nested' ) #NEWLINE# f1 . add ( task3 ) #NEWLINE# tasks = set ( [ task1 , task2 , f1 ] ) #NEWLINE# f = gf . Flow ( 'test' ) . add ( task1 , task2 , f1 ) #NEWLINE# for ( n , data ) in f . iter_nodes ( ) : #NEWLINE# #INDENT# self . assertTrue ( ( n in tasks ) ) #NEWLINE# self . assertDictEqual ( { #NEWLINE# #INDENT# #NEWLINE# #UNINDENT# } , data )