Esempio n. 1
0
    def test_if_check_if_hand_contains_quartes_works_correctly_when_there_is_not_quarte(
            self):
        player = Player()
        res = player.check_if_hand_contains_quartes({'10c', 'Jc', 'Qc', 'Kh'})
        exp = {'10c', 'Jc', 'Qc', 'Kh'}

        self.assertEqual(res, exp)
        self.assertEqual(player.quartes, [])
Esempio n. 2
0
    def test_if_check_if_hand_contains_quartes_works_correctly_when_there_are_multiple_quartes(
            self):
        player = Player()
        res = player.check_if_hand_contains_quartes(
            {'10c', 'Jc', 'Qc', 'Kc', '10h', 'Jh', 'Qh', 'Kh'})
        exp = set()

        self.assertEqual(res, exp)
        self.assertEqual(
            player.quartes,
            [['10c', 'Jc', 'Qc', 'Kc'], ['10h', 'Jh', 'Qh', 'Kh']])