kakoune/test/regression
Johannes Altmanninger 12310418b0 Allow map/unmap during mapping execution
Commits e49c0fb04 (unmap: fail if the mapping is currently executing,
2023-05-14) 42be0057a (map: fail if key is currently executing,
2023-06-24) fixed potential use-after-free issues. By doing so,
it broke configurations that in practice have not triggered any
crashes [1] [2].

For example with,

	set -remove global autocomplete insert
	hook global InsertCompletionShow .* %{
	    map window insert <esc> <c-o>
	}
	hook global InsertCompletionHide .* %{
	    unmap window insert <esc> <c-o>
	}

The execution of the <esc> mapping triggers InsertCompletionHide fails
at unmapping. This seems legit and I don't see an obvious alternative
way to write it (InsertIdle would not be correct though it would work
in practice).

Fix the regression by allowing map and unmap again while keeping the
mappings alive until they have finished executing.

Applying map/unmap immediately seems like the most obvious semantics.
Alternatively, we could apply them in between key presses.

[1]: <https://github.com/kak-lsp/kak-lsp/issues/689>
[2]: <https://github.com/alexherbo2/auto-pairs.kak/issues/60>
2023-07-20 09:18:23 +02:00
..
595-smart-search-unicode Expand env vars as list of strings 2020-03-02 20:53:28 +11:00
612-assertion-with-NormalBegin-hook
633-spurious-new-line-inserted-when-replacing-at-end
638-highlight-codepoint-with-bracket Add support for curly underline and separate underline color 2021-09-07 08:21:26 +10:00
643-crash-on-a-@-on-specially-crafted-buffer
654-crash-on-undo-after-macro
699-to-eol-from-eol Expand env vars as list of strings 2020-03-02 20:53:28 +11:00
704-crash-when-using-a-hook-on-NormalBegin-and-NormalEnd
733-selection-list-from-string-not-valid
743-crash-on-replace-undo
751-wrong-selection-after-undo test: Allow expect-style UI tests, testing any var 2019-10-13 14:57:24 -04:00
787-crash-after-S
809-alt-f-t-to-first-char test: Allow expect-style UI tests, testing any var 2019-10-13 14:57:24 -04:00
811-double-width-codepoints test: Allow expect-style UI tests, testing any var 2019-10-13 14:57:24 -04:00
844-prev-word-at-buffer-start test: Allow expect-style UI tests, testing any var 2019-10-13 14:57:24 -04:00
860-python-incorrect-commenting Add categories in rc/ 2019-03-21 01:06:16 +01:00
872-indentation-misbeahviour-c++ Add categories in rc/ 2019-03-21 01:06:16 +01:00
918-wrong-asterisk-inserted Add categories in rc/ 2019-03-21 01:06:16 +01:00
921-keep-empty-line-matches-all-lines test: Allow expect-style UI tests, testing any var 2019-10-13 14:57:24 -04:00
993-user-text-object
1014-ambiguous-kak_selections test: Allow expect-style UI tests, testing any var 2019-10-13 14:57:24 -04:00
1051-crash-on-empty-param
1053-crash-on-deletion-and-paste
1074-comment-leader-autoinsert-error Add categories in rc/ 2019-03-21 01:06:16 +01:00
1105-object-selection-behaviour test: Allow expect-style UI tests, testing any var 2019-10-13 14:57:24 -04:00
1111-unexpected-behaviour-on-new-line-in-comment Add categories in rc/ 2019-03-21 01:06:16 +01:00
1118-misaligned-comment-start Add categories in rc/ 2019-03-21 01:06:16 +01:00
1129-capture-groups-are-broken
1195-infinite-loop-in-regex-matching Make recurse regex opt-in with a -recurse switch instead of opt-out 2018-07-05 07:54:28 +10:00
1227-segfault-on-option-access
1233-corrent-cursor-handling-for-indent-objects test: Allow expect-style UI tests, testing any var 2019-10-13 14:57:24 -04:00
1275-replaced-range-split Rename highlighters that used an underscore to use a dash 2018-07-08 19:14:15 +10:00
1308-wrong-behaviour-of-kak-indent-on-newline test: Allow expect-style UI tests, testing any var 2019-10-13 14:57:24 -04:00
1382-column-highlighter-broken-on-horizontal-scroll Re-work line trimming to fix issues with column highighters 2022-07-13 12:24:14 +10:00
1433-scrolloff-broken-with-soft-wrap Add support for curly underline and separate underline color 2021-09-07 08:21:26 +10:00
1435-misplaced-cursor-with-show_matching-hl Add support for curly underline and separate underline color 2021-09-07 08:21:26 +10:00
1453-show_whitespaces-highlighter-breaks-tab-alignment Add support for curly underline and separate underline color 2021-09-07 08:21:26 +10:00
1459-assertion-on-wrapped-long-line Fix tests and required scripts to get back to green make test 2018-07-05 07:54:28 +10:00
1469-assert-on-repeat-insert
1504-assertion-on-incorrect-pipe-use Add + key to duplicate selections and <a-+> to merge overlapping ones 2021-02-15 09:01:14 +11:00
1518-wrong-undo-handling-with-fifo-buffers
1525-lua-indent-error Add categories in rc/ 2019-03-21 01:06:16 +01:00
1580-A-not-moving-to-eol Expand env vars as list of strings 2020-03-02 20:53:28 +11:00
1680-crash-with-dot-and-alt-semicolon Change a on end of line behaviour to be consistent 2018-07-05 08:00:14 +10:00
1731-wrap-hidden-buffer Add support for curly underline and separate underline color 2021-09-07 08:21:26 +10:00
1741-scrolloff-hides-end-of-lines Add support for curly underline and separate underline color 2021-09-07 08:21:26 +10:00
1829-unicode-as-string-delimiter
1902-regex-lookbehind-ignore-before-current-pos Expand env vars as list of strings 2020-03-02 20:53:28 +11:00
1904-select-empty-line-indent-gets-whole-buffer test: Allow expect-style UI tests, testing any var 2019-10-13 14:57:24 -04:00
1920-crash-on-python-in-docstring Add support for curly underline and separate underline color 2021-09-07 08:21:26 +10:00
1937-opening-missing-file-by-full-path-fails
1964-O-does-not-position-cursor-correctly
2030-custom-selection-nesting test: Allow expect-style UI tests, testing any var 2019-10-13 14:57:24 -04:00
2056-assert-on-small-window Fix test suite freeze 2019-11-12 09:39:37 -05:00
2078-assert-on-restoring-invalid-selections Expand env vars as list of strings 2020-03-02 20:53:28 +11:00
2129-inside-parentheses test: Allow expect-style UI tests, testing any var 2019-10-13 14:57:24 -04:00
2133-assert-on-rotate-contents
2245-wrap-long-word Add support for curly underline and separate underline color 2021-09-07 08:21:26 +10:00
2367-surround-with-tight-nesting test: Allow expect-style UI tests, testing any var 2019-10-13 14:57:24 -04:00
2420-discrepancy-in-star-behaviour Expand env vars as list of strings 2020-03-02 20:53:28 +11:00
2499-html-regions-assert test: Allow expect-style UI tests, testing any var 2019-10-13 14:57:24 -04:00
2562-column-highlighter-bleeding Add support for curly underline and separate underline color 2021-09-07 08:21:26 +10:00
2711-weird-regex-highlighter-behaviour Add support for curly underline and separate underline color 2021-09-07 08:21:26 +10:00
2737-segfault-on-WinDisplay-hook Add a test case for WinDisplay segfault 2019-02-17 11:21:26 +11:00
2755-segfault-on-double-wrap-highlighters Fix use of invalidated iterators in highlight_range 2019-03-05 20:31:40 +11:00
2861-backspace-merges-selections Do not merge selections on backspace in insert mode 2019-05-29 23:12:04 +10:00
2999-buggy-wrapping Add support for curly underline and separate underline color 2021-09-07 08:21:26 +10:00
3010-extra_word_chars-fails-with-other-buffers Filter non-extra_word_chars completion candidates using Codepoints 2019-07-09 19:36:57 +10:00
3025-last-buffer-does-not-work-in-draft-context Ensure current context switches away from buffer on delete-buffer 2019-07-22 20:26:39 +10:00
3041-invalid-regex-highlight-accross-regions Add support for curly underline and separate underline color 2021-09-07 08:21:26 +10:00
3048-word-wrapping-broken Add support for curly underline and separate underline color 2021-09-07 08:21:26 +10:00
3219-scroll-json-ui Add support for curly underline and separate underline color 2021-09-07 08:21:26 +10:00
3270-crash-in-autocomplete Update inserted range when generating InsertCompletionHide hook param 2020-01-08 20:33:26 +11:00
3275-crash-on-replace-at-buffer-start Fix replacing at begining of buffer 2019-12-31 12:49:24 +11:00
3349-crash-in-completion Fix invalid access to deleted line when updating insert completion 2020-03-14 13:49:52 +11:00
3388-command-line-parsing-does-not-preserve-invalid-utf8 Fix use of non-posix \x printf escape 2020-03-13 09:33:19 +11:00
3398-readonly-fifo-failure OpenBSD sh compat workaround: Move & within subshell invocation. Also see #2955 2021-12-17 11:59:18 +05:30
3439-parse-ascii-newline-as-return Parse ascii newline/tab/escape as special keys instead of control keys 2020-04-13 12:44:15 +10:00
3472-crash-on-to-sentence-start Fix select_sentence going past the end of the buffer 2020-05-10 15:13:15 +10:00
3478-crash-on-scroll Fix selections getting unsorted on scroll 2020-07-05 10:13:57 +10:00
3489-crash-on-paragraph-begin Fix crash when selecting previous paragraph at buffer begin 2020-05-17 14:15:48 +02:00
3495-crash-highlighting-hidden-lines Fix invalid regions with begin > end being generated 2020-05-28 20:58:46 +10:00
3544-capture-get-lost Fix select wiping captures 2020-06-07 14:12:54 +10:00
3669-pipe-adds-extra-newline Do not insert any end-of-line when piping data out 2022-01-24 21:53:33 +11:00
3733-modeline-parsing-off-by-one-line test: Implement a regression test for #3733 2020-09-16 11:00:15 +03:00
3735-modeline-arbitrary-code-execution test: Implement a regression test for #3735 2020-09-18 09:01:32 +03:00
3757-crash-on-capture-group-select Ensure that the capture group actually matched in select_matches 2020-09-22 21:14:40 +10:00
3799-incorrect-region-match Add support for curly underline and separate underline color 2021-09-07 08:21:26 +10:00
3909-crash-on-closing-buffer-with-user-mapping Move user mappings to <space> and keep/remove selection to , 2022-07-05 08:43:40 +10:00
4052-replace-range-vs-whitespace-highlighter-interaction Add support for curly underline and separate underline color 2021-09-07 08:21:26 +10:00
4086-ruby-deindenting-other-lines-than-keywords Remove electric behavior for end keyword 2021-06-06 00:30:50 +06:00
4378-line-explicit-completion-buggy Fix explicit line completion 2021-12-11 09:34:51 +11:00
4414-crash-on-paste-all Fix pasting all from empty register 2021-11-01 09:05:57 +11:00
4460-nul-byte-in-regex Fix parsing nul bytes in regex 2021-12-11 09:01:03 +11:00
4471-crash-on-alt-t-with-one-char-file Add a regression test for <a-t> on an 'empty' file. 2022-12-26 09:17:18 -05:00
4476-invalid-line-join Fix invalid line joining logic with multiple selection per line 2021-12-20 09:13:53 +11:00
4519-regex-alternation-priority Fix regex alternation execution priority 2022-02-02 14:51:17 +11:00
4521-alt-mapping-broken-in-lower-case-modes Fix modified keys not being mappable in goto mode 2022-02-01 13:36:36 +11:00
4601-int-min-arg Fix parsing of INT_MIN %arg 2022-05-05 20:05:24 +10:00
4605-fifo-hang Remove strace call in test that was committed by mistake 2022-06-03 16:01:58 +10:00
4659-scroll-issue-with-replace-ranges Refactor highlighting logic 2022-07-10 14:58:24 +10:00
4669-eol-highlight-to-column-highlighter Re-work line trimming to fix issues with column highighters 2022-07-13 12:24:14 +10:00
4674-show-whitespaces-horizontal-scroll-assert Remove out-of-date column computation in show-whitespaces 2022-07-19 22:47:39 +10:00
4750-crash-on-append-empty-output-at-end-of-buffer Add regression test for #4750 2022-10-19 20:33:22 +11:00
4753-assert-in-display-line-split Fix splitting of display atoms accross multi-columns codepoint 2022-10-17 17:48:39 +11:00
4779-crash-when-pasting-with-multiple-overlapping-selections Fix pasting after when selections are overlapping 2022-11-28 20:27:44 +11:00
4839-scroll-invalid-cursor Fix scroll_window not ensuring cursor lies on a codepoint start 2023-02-14 22:00:12 +11:00
4843-trim-front-split-glyph Disable trim-front-split-glyph test on platforms with broken Unicode support 2023-03-05 17:42:41 +01:00
4844-crash-on-empty-paste Fix crash when pasting at buffer end 2023-03-13 21:49:45 +11:00
4859-regex-invalid-behaviour Grow dual thread stack after pushing a thread on the next queue 2023-03-13 22:45:19 +11:00
4887-torn-utf8-sequence Stop _ from tearing multibyte UTF-8 sequences 2023-05-09 23:07:07 +02:00
4896-remap-executing-mapping Allow map/unmap during mapping execution 2023-07-20 09:18:23 +02:00
4896-unmap-executing-mapping Allow map/unmap during mapping execution 2023-07-20 09:18:23 +02:00
4926-crash-with-fold-and-ranges Fix highlighters being applied to empty display buffers 2023-06-19 12:55:55 +10:00
4927-crash-jumping-to-eol Fix invalid access of display line end 2023-06-20 13:09:03 +10:00
0-assert-on-itersel test: Allow expect-style UI tests, testing any var 2019-10-13 14:57:24 -04:00
0-autocomplete-overrules-completers Make <c-n> show completion menu again when autocomplete is off 2022-02-07 14:52:51 +01:00
0-comment-after-command
0-compute-modified-range-crash
0-crash-on-backspace-at-buffer-begin
0-crash-on-BufSetOption-hook
0-crash-on-delete-buffer-BufClose Fix crash when deleting buffers in a BufClose hook 2019-11-22 20:29:55 +11:00
0-crash-on-pipe-with-selection-access Add + key to duplicate selections and <a-+> to merge overlapping ones 2021-02-15 09:01:14 +11:00
0-crash-on-specialy-crafted-modeline
0-crash-on-tab-just-before-wrap-column Fix crash in TabulationHighlighter when wrapping just after a tab 2023-01-23 17:39:40 +11:00
0-deindent-on-mixed-indent-line Improve deindent behaviour with mixed indent 2018-12-13 17:35:16 +11:00
0-mouse-during-insert Give mouse-during-insert more slack on CI, it failed again on macOS 2023-04-24 18:31:05 +02:00
0-nothing-selected-on-prompt-initial-shift-tab Added shell command completion support to define-command and prompt 2018-10-03 09:46:31 -07:00
0-open-below-should-not-move-cursor-on-eol Expand env vars as list of strings 2020-03-02 20:53:28 +11:00
0-replace-last-eol-with-eol
0-rotate-at-eof-mutates-selection Cleanup replaced range selection logic 2019-12-18 11:36:17 +11:00
0-select-object-with-empty-begin-match Fix issue with select object and empty matches 2020-04-21 13:21:35 +10:00
0-spurious-undo-group-on-external Only commit undo groups when buffer was modified 2018-09-12 20:02:57 +10:00
0-undo-change-at-eof