예제 #1
0
 def testViewTree(self):
     root = View({'root':1}, None)
     children = ["A", "B", "C"]
     for s in children:
         root.add(View({s:1}, None))
     
     self.assertEquals(len(children), len(root.children)) 
예제 #2
0
 def testViewTreeParent(self):
     root = View({'root':1}, None)
     children = ["A", "B", "C"]
     for s in children:
         root.add(View({s:1}, None))
     
     for ch in root.children:
         self.assertTrue(ch.parent == root)