Example #1
0
    def test_failed_search(self):
        ts = TreeSearch()
        bfs = BreadthFirstSearch(ts)
        problem = Problem(1, TestActionsFunction(3), TestResultFunction(), TestGoalTest(5))

        result = bfs.search(problem)
        self.assertTrue(bfs.is_failure(result))
Example #2
0
    def test_failed_search(self):
        ts = TreeSearch()
        bfs = BreadthFirstSearch(ts)
        problem = Problem(1, TestActionsFunction(3), TestResultFunction(),
                          TestGoalTest(5))

        result = bfs.search(problem)
        self.assertTrue(bfs.is_failure(result))