summaryrefslogtreecommitdiff
path: root/tests/test_cards.py
blob: a5e4437466d62706121119c07eaff5c255e29d49 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
import unittest

from swiftstory.cards import Cards


class TestCards(unittest.TestCase):
    def test_get_cards_fr(self):
        self.assertTrue(Cards.get_white_cards("fr"))
        self.assertTrue(Cards.get_black_cards("fr"))

    def test_get_cards_en(self):
        self.assertTrue(Cards.get_white_cards("en"))
        self.assertTrue(Cards.get_black_cards("en"))

    def test_get_cards_unknown_language(self):
        with self.assertRaises(FileNotFoundError):
            Cards.get_white_cards("zz")
        with self.assertRaises(FileNotFoundError):
            Cards.get_black_cards("zz")