Ensure that keynames are parsed to their corresponding mapping. A keyname is expected to be of the following form: \\ such as \\ which would get parsed as "left".
(self)
| 13 | self.assertEqual(parse_keys(test_key), expected_keys) |
| 14 | |
| 15 | def test_keynames(self): |
| 16 | """Ensure that keynames are parsed to their corresponding mapping. |
| 17 | |
| 18 | A keyname is expected to be of the following form: \\<keyname> such as \\<left> |
| 19 | which would get parsed as "left". |
| 20 | """ |
| 21 | test_cases = [(f"\\<{keyname}>", [parsed_keyname]) for keyname, parsed_keyname in _keynames.items()] |
| 22 | for test_key, expected_keys in test_cases: |
| 23 | with self.subTest(f"{test_key} should be parsed as {expected_keys}"): |
| 24 | self.assertEqual(parse_keys(test_key), expected_keys) |
| 25 | |
| 26 | def test_escape_sequences(self): |
| 27 | """Ensure that escaping sequences are parsed to their corresponding mapping.""" |
nothing calls this directly
no test coverage detected