mirror of
https://github.com/neovim/neovim.git
synced 2025-02-25 18:55:25 -06:00
test(prompt_buffer_spec): include changes from v8.1.1984
I already ported v8.1.1984 previously, but hadn't updated prompt_buffer_spec to match test_prompt_buffer (which we have but due to Vim features such as term_sendkeys it's mostly skipped). Required for v8.2.3671.
This commit is contained in:
parent
d6258a9bad
commit
0f792b284f
@ -37,6 +37,7 @@ describe('prompt buffer', function()
|
|||||||
feed_command("new")
|
feed_command("new")
|
||||||
feed_command("set buftype=prompt")
|
feed_command("set buftype=prompt")
|
||||||
feed_command("call prompt_setcallback(bufnr(''), function('TextEntered'))")
|
feed_command("call prompt_setcallback(bufnr(''), function('TextEntered'))")
|
||||||
|
feed_command("eval bufnr('')->prompt_setprompt('cmd: ')")
|
||||||
end)
|
end)
|
||||||
|
|
||||||
after_each(function()
|
after_each(function()
|
||||||
@ -59,10 +60,10 @@ describe('prompt buffer', function()
|
|||||||
feed("i")
|
feed("i")
|
||||||
feed("hello\n")
|
feed("hello\n")
|
||||||
screen:expect([[
|
screen:expect([[
|
||||||
% hello |
|
cmd: hello |
|
||||||
Command: "hello" |
|
Command: "hello" |
|
||||||
Result: "hello" |
|
Result: "hello" |
|
||||||
% ^ |
|
cmd: ^ |
|
||||||
[Prompt] [+] |
|
[Prompt] [+] |
|
||||||
other buffer |
|
other buffer |
|
||||||
~ |
|
~ |
|
||||||
@ -101,7 +102,7 @@ describe('prompt buffer', function()
|
|||||||
feed("i")
|
feed("i")
|
||||||
feed("hello<BS><BS>")
|
feed("hello<BS><BS>")
|
||||||
screen:expect([[
|
screen:expect([[
|
||||||
% hel^ |
|
cmd: hel^ |
|
||||||
~ |
|
~ |
|
||||||
~ |
|
~ |
|
||||||
~ |
|
~ |
|
||||||
@ -114,7 +115,7 @@ describe('prompt buffer', function()
|
|||||||
]])
|
]])
|
||||||
feed("<Left><Left><Left><BS>-")
|
feed("<Left><Left><Left><BS>-")
|
||||||
screen:expect([[
|
screen:expect([[
|
||||||
% -^hel |
|
cmd: -^hel |
|
||||||
~ |
|
~ |
|
||||||
~ |
|
~ |
|
||||||
~ |
|
~ |
|
||||||
@ -127,7 +128,7 @@ describe('prompt buffer', function()
|
|||||||
]])
|
]])
|
||||||
feed("<C-O>lz")
|
feed("<C-O>lz")
|
||||||
screen:expect([[
|
screen:expect([[
|
||||||
% -hz^el |
|
cmd: -hz^el |
|
||||||
~ |
|
~ |
|
||||||
~ |
|
~ |
|
||||||
~ |
|
~ |
|
||||||
@ -140,7 +141,7 @@ describe('prompt buffer', function()
|
|||||||
]])
|
]])
|
||||||
feed("<End>x")
|
feed("<End>x")
|
||||||
screen:expect([[
|
screen:expect([[
|
||||||
% -hzelx^ |
|
cmd: -hzelx^ |
|
||||||
~ |
|
~ |
|
||||||
~ |
|
~ |
|
||||||
~ |
|
~ |
|
||||||
|
Loading…
Reference in New Issue
Block a user