MCPcopy Create free account
hub / github.com/bpython/bpython / test_keymap_keyerror

Method test_keymap_keyerror

bpython/test/test_keys.py:30–34  ·  view source on GitHub ↗

Verify keys.KeyMap raising KeyError when getting undefined key

(self)

Source from the content-addressed store, hash-verified

28 self.assertEqual(keys.cli_key_dispatch["C-a"], ("\x01", "^A"))
29
30 def test_keymap_keyerror(self):
31 """Verify keys.KeyMap raising KeyError when getting undefined key"""
32 with self.assertRaises(KeyError):
33 keys.cli_key_dispatch["C-asdf"]
34 keys.cli_key_dispatch["C-qwerty"]
35
36
37class TestUrwidKeys(unittest.TestCase):

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected