def test_releasing_keys_works(self): vm = VM() for key in range(0, 16): vm.press(key) for key in range(0, 16): vm.release(key) assert not vm.pressed(key)
def test_pressing_keys_sets_state(self): vm = VM() for key in range(0, 16): vm.press(key) assert vm.pressed(key)