aboutsummaryrefslogtreecommitdiff
path: root/src/nvim/testdir
diff options
context:
space:
mode:
authorShougo Matsushita <Shougo.Matsu@gmail.com>2017-03-04 12:24:49 +0900
committerShougo Matsushita <Shougo.Matsu@gmail.com>2017-03-05 12:02:32 +0900
commit4303399c10b7106ccf350e8a419fe3c15b81c8e0 (patch)
tree593316600650cea8263bf52314b4a4c6b504b87d /src/nvim/testdir
parentaf63f321295a37e411aac82b56a5548bdbe82877 (diff)
downloadrneovim-4303399c10b7106ccf350e8a419fe3c15b81c8e0.tar.gz
rneovim-4303399c10b7106ccf350e8a419fe3c15b81c8e0.tar.bz2
rneovim-4303399c10b7106ccf350e8a419fe3c15b81c8e0.zip
vim-patch:8.0.0319
Problem: Insert mode completion does not respect "start" in 'backspace'. Solution: Check whether backspace can go before where insert started. (Hirohito Higashi) https://github.com/vim/vim/commit/190b04cdd936f4696c22466b7f077f9371d96580
Diffstat (limited to 'src/nvim/testdir')
-rw-r--r--src/nvim/testdir/test_popup.vim20
1 files changed, 20 insertions, 0 deletions
diff --git a/src/nvim/testdir/test_popup.vim b/src/nvim/testdir/test_popup.vim
index edc6336aa7..259e0149af 100644
--- a/src/nvim/testdir/test_popup.vim
+++ b/src/nvim/testdir/test_popup.vim
@@ -482,6 +482,26 @@ func Test_completion_ctrl_e_without_autowrap()
q!
endfunc
+func Test_completion_respect_bs_option()
+ new
+ let li = ["aaa", "aaa12345", "aaaabcdef", "aaaABC"]
+
+ set bs=indent,eol
+ call setline(1, li)
+ 1
+ call feedkeys("A\<C-X>\<C-N>\<C-P>\<BS>\<BS>\<BS>\<Esc>", "tx")
+ call assert_equal('aaa', getline(1))
+
+ %d
+ set bs=indent,eol,start
+ call setline(1, li)
+ 1
+ call feedkeys("A\<C-X>\<C-N>\<C-P>\<BS>\<BS>\<BS>\<Esc>", "tx")
+ call assert_equal('', getline(1))
+
+ bw!
+endfunc
+
func CompleteUndo() abort
call complete(1, g:months)
return ''