#NEWLINE# def testHierarchyConstruction( self ) : #NEWLINE# #INDENT# ' Test hierarchy construction ' #NEWLINE# uids = self . uids #NEWLINE# h = S3Hierarchy ( 'test_lhierarchy' ) #NEWLINE# assertEqual = self . assertEqual #NEWLINE# assertTrue = self . assertTrue #NEWLINE# roots = self . roots #NEWLINE# assertEqual ( len ( roots ) , 2 ) #NEWLINE# assertTrue ( ( uids [ 'LHIERARCHY1' ] in roots ) ) #NEWLINE# assertTrue ( ( uids [ 'LHIERARCHY2' ] in roots ) ) #NEWLINE# nodes = h . nodes #NEWLINE# assertEqual ( len ( nodes ) , len ( uids ) ) #NEWLINE# assertTrue ( all ( ( ( node_id in nodes ) for node_id in uids . values ( ) ) ) )