#NEWLINE# def testExpand( self ) : #NEWLINE# #INDENT# c = GafferUI . ListContainer ( GafferUI . ListContainer . Orientation . Vertical ) #NEWLINE# with c : #NEWLINE# #INDENT# ca = TestWidget ( 'a' ) #NEWLINE# cb = TestWidget ( 'b' , parenting = { #NEWLINE# #INDENT# 'expand' : True , #NEWLINE# #UNINDENT# } ) #NEWLINE# cc = TestWidget ( 'c' , parenting = { #NEWLINE# #INDENT# 'expand' : True , #NEWLINE# #UNINDENT# } ) #NEWLINE# #UNINDENT# self . assertEqual ( c . getExpand ( ca ) , False ) #NEWLINE# self . assertEqual ( c . getExpand ( cb ) , True ) #NEWLINE# self . assertEqual ( c . getExpand ( cc ) , True ) #NEWLINE# c . setExpand ( ca , True ) #NEWLINE# c . setExpand ( cb , False ) #NEWLINE# self . assertEqual ( c . getExpand ( ca ) , True ) #NEWLINE# self . assertEqual ( c . getExpand ( cb ) , False ) #NEWLINE# self . assertEqual ( c . getExpand ( cc ) , True ) #NEWLINE# cd = TestWidget ( 'd' ) #NEWLINE# c [ 0 ] = cd #NEWLINE# self . assertEqual ( c . getExpand ( cd ) , True ) #NEWLINE# self . assertEqual ( c . getExpand ( cb ) , False ) #NEWLINE# self . assertEqual ( c . getExpand ( cc ) , True )