def test(self, _, node_idents, min_path_len, expected_node_idents):
        root = TreeMaker.from_node_idents(node_idents)
        remove_nodes(root, min_path_len)

        root_expected = TreeMaker.from_node_idents(expected_node_idents)
        self.assertEqual(root, root_expected)
示例#2
0
    def test_all_removed(self, _, node_idents, min_path_len):
        root = TreeMaker.from_node_idents(node_idents)
        root_produced = remove_nodes(root, min_path_len)

        self.assertEqual(root_produced, None)