18
18
self.edge_add('A', 'G', 'H', 'I', 'B')
19
19
self.edge_add('A', 'J', 'K', 'L', 'M', 'N')
23
23
descendants = {'A':set()}
25
25
for ancestor in self.graph[node]:
26
26
if ancestor not in descendants:
27
27
descendants[ancestor] = set()
28
28
descendants[ancestor].add(node)
30
35
self.assertEqual(nodes[0], 'D')
31
36
assert nodes[1] in ('N', 'C')
32
37
assert nodes[2] in ('N', 'C')