Ejemplo n.º 1
0
 def test_DeepAllNodesOneNodeIn(self):
     node = BSTNode(1, 1, None)
     tree = BST(node)
     result = tree.DeepAllNodes(0)
     correct_answer = tuple([node])
     self.assertEqual(result, correct_answer)
Ejemplo n.º 2
0
 def test_DeepAllNodesEmptyPre(self):
     tree = BST(None)
     result = tree.DeepAllNodes(2)
     correct_answer = tuple()
     self.assertEqual(result, correct_answer)