Ejemplo n.º 1
0
 def test_player_pc_turn(self):
     """
     Tests the player_pc_turn method.
     """
     deck_game = Game()
     deck_game.aggressive = True
     deck_game.set_up_game()
     pc_ds = deck_game.player_pc.deck.size()
     deck_game.player_pc_turn()
     self.assertEqual(deck_game.player_pc.deck.size(), pc_ds - 5)
Ejemplo n.º 2
0
 def test_set_up_game(self):
     """
     Tests the set_up method.
     """
     deck_game = Game()
     deck_game.set_up_game()
     self.assertEqual(deck_game.player_1.deck.size(),
                      deck_game.player_pc.deck.size())
     self.assertEqual(deck_game.player_1.hand.size(),
                      deck_game.player_1.handsize)
     self.assertEqual(deck_game.player_pc.hand.size(),
                      deck_game.player_pc.handsize)
     self.assertGreater(deck_game.central['deck'].size(), 0)