(self)
| 149 | self.checkletter("FULLWIDTH LATIN SMALL LETTER A", "\uFF41") |
| 150 | |
| 151 | def test_aliases(self): |
| 152 | # Check that the aliases defined in the NameAliases.txt file work. |
| 153 | # This should be updated when new aliases are added or the file |
| 154 | # should be downloaded and parsed instead. See #12753. |
| 155 | aliases = [ |
| 156 | ('LATIN CAPITAL LETTER GHA', 0x01A2), |
| 157 | ('LATIN SMALL LETTER GHA', 0x01A3), |
| 158 | ('KANNADA LETTER LLLA', 0x0CDE), |
| 159 | ('LAO LETTER FO FON', 0x0E9D), |
| 160 | ('LAO LETTER FO FAY', 0x0E9F), |
| 161 | ('LAO LETTER RO', 0x0EA3), |
| 162 | ('LAO LETTER LO', 0x0EA5), |
| 163 | ('TIBETAN MARK BKA- SHOG GI MGO RGYAN', 0x0FD0), |
| 164 | ('YI SYLLABLE ITERATION MARK', 0xA015), |
| 165 | ('PRESENTATION FORM FOR VERTICAL RIGHT WHITE LENTICULAR BRACKET', 0xFE18), |
| 166 | ('BYZANTINE MUSICAL SYMBOL FTHORA SKLIRON CHROMA VASIS', 0x1D0C5) |
| 167 | ] |
| 168 | for alias, codepoint in aliases: |
| 169 | self.checkletter(alias, chr(codepoint)) |
| 170 | name = unicodedata.name(chr(codepoint)) |
| 171 | self.assertNotEqual(name, alias) |
| 172 | self.assertEqual(unicodedata.lookup(alias), |
| 173 | unicodedata.lookup(name)) |
| 174 | with self.assertRaises(KeyError): |
| 175 | unicodedata.ucd_3_2_0.lookup(alias) |
| 176 | |
| 177 | def test_aliases_names_in_pua_range(self): |
| 178 | # We are storing aliases in the PUA 15, but their names shouldn't leak |
nothing calls this directly
no test coverage detected