aboutsummaryrefslogtreecommitdiff
path: root/test/old
diff options
context:
space:
mode:
authorzeertzjq <zeertzjq@outlook.com>2023-06-16 08:13:42 +0800
committerzeertzjq <zeertzjq@outlook.com>2023-06-16 08:55:05 +0800
commit11060793d6544e893f31d65e8f964453c463407c (patch)
treefc1d9c844283da12dfe91b716f97976b66bcfabd /test/old
parentcba07dad494558a4a06e25a35521041864697be3 (diff)
downloadrneovim-11060793d6544e893f31d65e8f964453c463407c.tar.gz
rneovim-11060793d6544e893f31d65e8f964453c463407c.tar.bz2
rneovim-11060793d6544e893f31d65e8f964453c463407c.zip
vim-patch:9.0.1635: error message is cleared when removing mode message
Problem: Error message is cleared when removing mode message. Solution: Also reset flags when the message is further down. https://github.com/vim/vim/commit/da51ad51bf4fbd66619786d0e6a83fb3ca09930b Co-authored-by: Bram Moolenaar <Bram@vim.org>
Diffstat (limited to 'test/old')
-rw-r--r--test/old/testdir/test_messages.vim9
1 files changed, 8 insertions, 1 deletions
diff --git a/test/old/testdir/test_messages.vim b/test/old/testdir/test_messages.vim
index 766b04d154..31c8b9942b 100644
--- a/test/old/testdir/test_messages.vim
+++ b/test/old/testdir/test_messages.vim
@@ -352,7 +352,8 @@ func Test_message_not_cleared_after_mode()
endfunction
set showmode
set cmdheight=1
- call setline(1, ['one', 'two', 'three'])
+ call test_settime(1)
+ call setline(1, ['one', 'NoSuchFile', 'three'])
END
call writefile(lines, 'XmessageMode', 'D')
let buf = RunVimInTerminal('-S XmessageMode', {'rows': 10})
@@ -366,6 +367,12 @@ func Test_message_not_cleared_after_mode()
call TermWait(buf)
call VerifyScreenDump(buf, 'Test_message_not_cleared_after_mode_2', {})
+ " removing the mode message used to also clear the error message
+ call term_sendkeys(buf, ":set cmdheight=2\<CR>")
+ call term_sendkeys(buf, '2GvEgf')
+ call TermWait(buf)
+ call VerifyScreenDump(buf, 'Test_message_not_cleared_after_mode_3', {})
+
call StopVimInTerminal(buf)
endfunc