예제 #1
0
    def test_move_by_alias(self):
        hallway = HallwayRoom()
        outside = OutsideRoom()
        hallway.add_exit("north", outside)

        self.assertEqual(hallway.move("n"), outside)
예제 #2
0
    def test_move_non_exit(self):
        hallway = HallwayRoom()
        outside = OutsideRoom()
        hallway.add_exit("north", outside)

        self.assertIsNone(hallway.move("south"))