def test_over_with_full_fours_board(self): board = BaseBoard(4) board.board_state = {1:"o",2:"x",3:"x",4:"o", 5:"x",6:"o",7:"o",8:"x", 9:"x",10:"o",11:"o",12:"x", 13:"x",14:"x",15:"o",16:"x"} self.assertFalse(board.winner()) self.assertTrue(board.over())
def test_over_with_win(self): self.assertFalse(BaseBoard(base=3).over()) board = BaseBoard(base=3) board.board_state = {1:"x",2:"x",3:"x"} self.assertTrue(board.over())
def test_over_with_full_threes_board(self): board = BaseBoard(3) board.board_state = {1:"x",2:"x",3:"o", 4:"o",5:"x",6:"x", 7:"x",8:"o",9:"o"} self.assertEqual(True,board.over())
def test_over_with_non_full_board(self): board = BaseBoard(3) board.board_state = {1:"x", 2:"o"} self.assertFalse(board.over())