Exemplo n.º 1
0
    def test_matches_international_e_letters(self):
        for alpha in 'еэє':
            station = Station('К{0}сів'.format(alpha), '')

            self.assertTrue(station.matches('е'))
            self.assertTrue(station.matches('э'))
            self.assertTrue(station.matches('є'))
Exemplo n.º 2
0
    def test_matches_international_i_letters(self):
        for alpha in 'ыиі':
            station = Station('К{0}ев'.format(alpha), '')

            self.assertTrue(station.matches('ы'))
            self.assertTrue(station.matches('и'))
            self.assertTrue(station.matches('і'))
Exemplo n.º 3
0
    def test_matches_complex_international_letters(self):
        station = Station('КікыкиКєкекэкие', '')

        self.assertTrue(station.matches('кИкІкЫкЭкЄкЕкиї'))
Exemplo n.º 4
0
    def test_doesnt_match_other_letters(self):
        station = Station('Киев', '')

        self.assertEqual(False, station.matches('жЖ'))
Exemplo n.º 5
0
    def test_matches_middle_of_name(self):
        station = Station('Кишинев', '')

        self.assertTrue(station.matches('ишинев'))
Exemplo n.º 6
0
    def test_matches_is_case_insensitive(self):
        station = Station('Киев', '')

        self.assertTrue(station.matches('Ки'))
        self.assertTrue(station.matches('КИ'))