#NEWLINE# def testLayer( self ) : #NEWLINE# #INDENT# s = p . Space ( ) #NEWLINE# b1 = p . Body ( 1 , 1 ) #NEWLINE# b2 = p . Body ( 1 , 1 ) #NEWLINE# b3 = p . Body ( 1 , 1 ) #NEWLINE# b4 = p . Body ( 1 , 1 ) #NEWLINE# c1 = p . Circle ( b1 , 2 ) #NEWLINE# c2 = p . Circle ( b2 , 2 ) #NEWLINE# c3 = p . Circle ( b3 , 2 ) #NEWLINE# c4 = p . Circle ( b4 , 2 ) #NEWLINE# c1 . layers = 2 #NEWLINE# c2 . layers = 1 #NEWLINE# c3 . layers = 3 #NEWLINE# s . add ( b2 , b3 , b4 , c2 , c3 , c4 ) #NEWLINE# shapes = s . shape_query ( c1 ) #NEWLINE# self . assertEqual ( len ( shapes ) , 2 ) #NEWLINE# self . assert_ ( ( c3 in shapes ) ) #NEWLINE# self . assert_ ( ( c4 in shapes ) )