def testFindGc1(self): gc1 = find_path(self.mp4, './child1/gc') self.assertNotEqual(None, gc1) gc2 = find_path(self.mp4, './child1/grandchild') self.assertNotEqual(None, gc2) gc3 = find_path(self.mp4, 'child1/grandchild') self.assertNotEqual(None, gc3) self.assertEquals(gc1.type, gc2.type) self.assertEquals(gc2.type, gc3.type)
def find(self, path): return find_path(self, path)
def testFindStar(self): gc1 = find_path(self.mp4, '*/gc') self.assertNotEquals(None, gc1)
def testFindSelf(self): root = find_path(self.mp4, '.') self.assertEquals(root.type, 'root')