def testGame(self): b1 = Board() g = Game(b1) p1 = Point(0, 1) p2 = Point(0, 2) p3 = Point(0, 3) g.adS((p1, p2, p3)) p1 = Point(1, 1) p2 = Point(1, 2) p3 = Point(1, 3) g.adS((p1, p2, p3)) p1 = Point(3, 1) p2 = Point(3, 2) p3 = Point(3, 3) g.adS((p1, p2, p3)) with self.assertRaises(Exception): g.adS((p1, p2, p3)) g.chooseAi() while g.isWon() == False: g.makeMA() self.assertEqual(g.isWon(), True)