mirror of
https://github.com/neovim/neovim.git
synced 2025-10-02 16:08:36 +00:00
vim-patch:8.2.3461: distinguish Normal and Terminal-Normal mode #15878
Problem: Cannot distinguish Normal and Terminal-Normal mode.
Solution: Make mode() return "nt" for Terminal-Normal mode. (issue vim/vim#8856)
72406a4bd2
This commit is contained in:
@@ -710,6 +710,14 @@ func Test_mode()
|
||||
call assert_equal('c-cv', g:current_modes)
|
||||
" How to test Ex mode?
|
||||
|
||||
if has('terminal')
|
||||
term
|
||||
call feedkeys("\<C-W>N", 'xt')
|
||||
call assert_equal('n', mode())
|
||||
call assert_equal('nt', mode(1))
|
||||
call feedkeys("aexit\<CR>", 'xt')
|
||||
endif
|
||||
|
||||
bwipe!
|
||||
iunmap <F2>
|
||||
xunmap <F2>
|
||||
|
Reference in New Issue
Block a user