(self)
| 118 | |
| 119 | @unittest.expectedFailure # TODO: RUSTPYTHON |
| 120 | def test_aliases(self): |
| 121 | # Check that the aliases defined in the NameAliases.txt file work. |
| 122 | # This should be updated when new aliases are added or the file |
| 123 | # should be downloaded and parsed instead. See #12753. |
| 124 | aliases = [ |
| 125 | ('LATIN CAPITAL LETTER GHA', 0x01A2), |
| 126 | ('LATIN SMALL LETTER GHA', 0x01A3), |
| 127 | ('KANNADA LETTER LLLA', 0x0CDE), |
| 128 | ('LAO LETTER FO FON', 0x0E9D), |
| 129 | ('LAO LETTER FO FAY', 0x0E9F), |
| 130 | ('LAO LETTER RO', 0x0EA3), |
| 131 | ('LAO LETTER LO', 0x0EA5), |
| 132 | ('TIBETAN MARK BKA- SHOG GI MGO RGYAN', 0x0FD0), |
| 133 | ('YI SYLLABLE ITERATION MARK', 0xA015), |
| 134 | ('PRESENTATION FORM FOR VERTICAL RIGHT WHITE LENTICULAR BRACKET', 0xFE18), |
| 135 | ('BYZANTINE MUSICAL SYMBOL FTHORA SKLIRON CHROMA VASIS', 0x1D0C5) |
| 136 | ] |
| 137 | for alias, codepoint in aliases: |
| 138 | self.checkletter(alias, chr(codepoint)) |
| 139 | name = unicodedata.name(chr(codepoint)) |
| 140 | self.assertNotEqual(name, alias) |
| 141 | self.assertEqual(unicodedata.lookup(alias), |
| 142 | unicodedata.lookup(name)) |
| 143 | with self.assertRaises(KeyError): |
| 144 | unicodedata.ucd_3_2_0.lookup(alias) |
| 145 | |
| 146 | def test_aliases_names_in_pua_range(self): |
| 147 | # We are storing aliases in the PUA 15, but their names shouldn't leak |
nothing calls this directly
no test coverage detected