示例#1
0
 def test_get_orientation_none(self):
     game = Game()
     orientation = game.get_orientation(
         [Board.MIDDLE, (Board.MIDDLE[0] + 1, Board.MIDDLE[1] + 1)])
     self.assertEqual(orientation, Orientation.NONE)
示例#2
0
 def test_get_orientation_horizontal(self):
     game = Game()
     orientation = game.get_orientation(
         [Board.MIDDLE, (Board.MIDDLE[0], Board.MIDDLE[1] + 1)])
     self.assertEqual(orientation, Orientation.HORIZONTAL)
示例#3
0
 def test_get_orientation_vertical(self):
     game = Game()
     orientation = game.get_orientation(
         [Board.MIDDLE, (Board.MIDDLE[0] + 1, Board.MIDDLE[1])])
     self.assertEqual(orientation, Orientation.VERTICAL)
示例#4
0
 def test_get_orientation_single(self):
     game = Game()
     orientation = game.get_orientation([Board.MIDDLE])
     self.assertEqual(orientation, Orientation.HORIZONTAL)