mirror of
https://github.com/neovim/neovim.git
synced 2024-12-22 12:15:06 -07:00
vim-patch:8.1.0840: getchar(0) never returns a character in the terminal
Problem: getchar(0) never returns a character in the terminal.
Solution: Call wait_func() at least once.
12dfc9eef1
This commit is contained in:
parent
4c4bcecc4a
commit
a2554858df
@ -253,6 +253,16 @@ func Test_peek_and_get_char()
|
||||
call timer_stop(intr)
|
||||
endfunc
|
||||
|
||||
func Test_getchar_zero()
|
||||
call timer_start(20, {id -> feedkeys('x', 'L')})
|
||||
let c = 0
|
||||
while c == 0
|
||||
let c = getchar(0)
|
||||
sleep 10m
|
||||
endwhile
|
||||
call assert_equal('x', nr2char(c))
|
||||
endfunc
|
||||
|
||||
func Test_ex_mode()
|
||||
" Function with an empty line.
|
||||
func Foo(...)
|
||||
|
Loading…
Reference in New Issue
Block a user