def test_curly_right_not_curly_current(self): mock_event = MagicMock() mock_event.cli.current_buffer.document.current_char = "n" curly_right(mock_event) mock_event.cli.current_buffer.insert_text.assert_has_calls([call("}")])
def test_curly_right_not_curly_current(binder): binder.cli.current_buffer.document.current_char = "n" curly_right(binder) binder.cli.current_buffer.insert_text.assert_has_calls([call("}")])
def test_curly_right_curly_current(self): mock_event = MagicMock() mock_event.cli.current_buffer.document.current_char = "}" curly_right(mock_event) mock_event.cli.current_buffer.cursor_right.assert_called_once_with()
def test_curly_right_curly_current(binder): binder.cli.current_buffer.document.current_char = "}" curly_right(binder) binder.cli.current_buffer.cursor_right.assert_called_once_with()