forked from aniani/vim
patch 8.2.2014: using CTRL-O in a prompt buffer moves cursor to start
Problem: Using CTRL-O in a prompt buffer moves cursor to start of the line. Solution: Do not move the cursor when restarting edit. (closes #7330)
This commit is contained in:
@@ -85,9 +85,12 @@ func Test_prompt_editing()
|
||||
call term_sendkeys(buf, left . left . left . bs . '-')
|
||||
call WaitForAssert({-> assert_equal('cmd: -hel', term_getline(buf, 1))})
|
||||
|
||||
call term_sendkeys(buf, "\<C-O>lz")
|
||||
call WaitForAssert({-> assert_equal('cmd: -hzel', term_getline(buf, 1))})
|
||||
|
||||
let end = "\<End>"
|
||||
call term_sendkeys(buf, end . "x")
|
||||
call WaitForAssert({-> assert_equal('cmd: -helx', term_getline(buf, 1))})
|
||||
call WaitForAssert({-> assert_equal('cmd: -hzelx', term_getline(buf, 1))})
|
||||
|
||||
call term_sendkeys(buf, "\<C-U>exit\<CR>")
|
||||
call WaitForAssert({-> assert_equal('other buffer', term_getline(buf, 1))})
|
||||
|
||||
Reference in New Issue
Block a user