#NEWLINE# def test_not_getting_links( self ) : #NEWLINE# #INDENT# traj = Trajectory ( ) #NEWLINE# traj . f_add_parameter_group ( 'test.test3' ) #NEWLINE# traj . f_add_parameter_group ( 'test2' ) #NEWLINE# traj . test . f_add_link ( 'circle1' , traj . test2 ) #NEWLINE# traj . test2 . f_add_link ( 'circle2' , traj . test ) #NEWLINE# self . assertTrue ( ( traj . test . circle1 is traj . test2 ) ) #NEWLINE# traj . v_with_links = False #NEWLINE# with self . assertRaises ( AttributeError ) : #NEWLINE# #INDENT# traj . test . circle1 #NEWLINE# #UNINDENT# found = False #NEWLINE# for item in traj . test . f_iter_nodes ( recursive = True , with_links = True ) : #NEWLINE# #INDENT# if ( item is traj . test2 ) : #NEWLINE# #INDENT# found = True #NEWLINE# #UNINDENT# #UNINDENT# self . assertTrue ( found ) #NEWLINE# for item in traj . test . f_iter_nodes ( recursive = True , with_links = False ) : #NEWLINE# #INDENT# if ( item is item . test2 ) : #NEWLINE# #INDENT# self . assertTrue ( False ) #NEWLINE# #UNINDENT# #UNINDENT# traj . v_with_links = True #NEWLINE# self . assertTrue ( ( 'circle1' in traj ) ) #NEWLINE# self . assertFalse ( traj . f_contains ( 'circle1' , with_links = False ) ) #NEWLINE# self . assertTrue ( ( 'circle1' in traj . test ) ) #NEWLINE# self . assertFalse ( traj . test . f_contains ( 'circle1' , with_links = False ) ) #NEWLINE# self . assertTrue ( ( traj . test2 . test3 is traj . par . test . test3 ) ) #NEWLINE# traj . v_with_links = False #NEWLINE# with self . assertRaises ( AttributeError ) : #NEWLINE# #INDENT# traj . test2 . test3 #NEWLINE# #UNINDENT# traj . v_with_links = True #NEWLINE# self . assertTrue ( ( traj [ 'test2.test3' ] is traj . test3 ) ) #NEWLINE# with self . assertRaises ( AttributeError ) : #NEWLINE# #INDENT# traj . f_get ( 'test2.test3' , with_links = False )