示例#1
0
 def testFindGoalVeryShortMazeShouldBeOneOne(self):
     maze = Maze('mazes/very_short_maze.txt', QueueFrontier())
     self.assertEqual(Point(1, 1), maze._find_goal())
示例#2
0
 def testFindGoalMazeShortestPossibleMazeShouldBeOneOne(self):
     maze = Maze('mazes/shortest_possible_maze.txt', QueueFrontier())
     self.assertEqual(Point(1, 1), maze._find_goal())
示例#3
0
 def testFindGoalMazeWithCycleShouldBeTwoOne(self):
     maze = Maze('mazes/maze_with_cycle.txt', QueueFrontier())
     self.assertEqual(Point(2, 1), maze._find_goal())
示例#4
0
 def testFindGoalMazeWithTurnShouldBeThreeOne(self):
     maze = Maze('mazes/maze_with_turn.txt', QueueFrontier())
     self.assertEqual(Point(3, 1), maze._find_goal())
示例#5
0
 def testFindGoalLinearMazeShouldBeOneOne(self):
     maze = Maze('mazes/linear_maze.txt', QueueFrontier())
     self.assertEqual(Point(1, 1), maze._find_goal())