From 31513a6f2df7cce9a7ae19fcd7c0e9c2404ea1e9 Mon Sep 17 00:00:00 2001 From: Jan Edmund Lazo Date: Fri, 18 Sep 2020 21:46:40 -0400 Subject: [PATCH] vim-patch:8.1.1972: no proper test for getchar() Problem: No proper test for getchar(). Solution: Add a test with special characters. https://github.com/vim/vim/commit/5d712e4672c6c8cf7f35cfb7d8eb7e8aa24062ac N/A patches for version.c: vim-patch:8.1.0285: compiler warning for conversion Problem: Compiler warning for conversion. Solution: Add a type cast. (Mike Williams) https://github.com/vim/vim/commit/d7cc16357083c4fc4271e25fb36c4fbaee99e0f1 vim-patch:8.1.1782: MS-Windows: system() has temp file error with 'noshelltemp' Problem: MS-Windows: system() has temp file error with 'noshelltemp'. Solution: Check s_dont_use_vimrun. (Ken Takata, closes vim/vim#4754) https://github.com/vim/vim/commit/0e6bfb9b2eb108d96a49ac4f8dc638c2eefeda2b vim-patch:8.2.0240: using memory after it was freed Problem: Using memory after it was freed. (Dominique Pelle) Solution: Do not mix converion buffer with other buffer. https://github.com/vim/vim/commit/408030e8d053fe1c871b2fc366363a30ed98c889 vim-patch:8.2.1549: "r" fails if 'esckeys' is off and modifyOtherKeys is used Problem: The "r" command fails for keys with modifiers if 'esckeys' is off and modifyOtherKeys is used. (Lauri Tirkkonen) Solution: Temporarily disable bracketed paste and modifyOtherKeys if 'esckeys' is off. (closes vim/vim#6809) https://github.com/vim/vim/commit/ca774f67534e6d1843fda9d1dc9a899972d27577 vim-patch:8.2.1676: compiler warnings for function typecast Problem: Compiler warnings for function typecast. Solution: Add an intermediate cast to "void *". https://github.com/vim/vim/commit/a4224860a498eb870280130e00fe6f376b7a2e6b vim-patch:8.2.1696: unused (duplicate) macros Problem: Unused (duplicate) macros. Solution: Remove the macros. https://github.com/vim/vim/commit/2c12f890551bbdf5605472a4d711d48a273685d7 --- src/nvim/testdir/test_functions.vim | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/src/nvim/testdir/test_functions.vim b/src/nvim/testdir/test_functions.vim index 6b45ac61d1..9a05db1188 100644 --- a/src/nvim/testdir/test_functions.vim +++ b/src/nvim/testdir/test_functions.vim @@ -1221,6 +1221,24 @@ func Test_reg_executing_and_recording() unlet s:reg_stat endfunc +func Test_getchar() + throw 'skipped: Nvim does not support test_setmouse()' + call feedkeys('a', '') + call assert_equal(char2nr('a'), getchar()) + + call test_setmouse(1, 3) + let v:mouse_win = 9 + let v:mouse_winid = 9 + let v:mouse_lnum = 9 + let v:mouse_col = 9 + call feedkeys("\", '') + call assert_equal("\", getchar()) + call assert_equal(1, v:mouse_win) + call assert_equal(win_getid(1), v:mouse_winid) + call assert_equal(1, v:mouse_lnum) + call assert_equal(3, v:mouse_col) +endfunc + func Test_libcall_libcallnr() if !has('libcall') return