diff options
author | Bram Moolenaar <Bram@vim.org> | 2018-04-30 17:21:03 +0200 |
---|---|---|
committer | Bram Moolenaar <Bram@vim.org> | 2018-04-30 17:21:03 +0200 |
commit | 35e802e713382d7e76232ad344af7dcd577e43de (patch) | |
tree | 07ddbdc3c26ccdaf45ae1f7b7f7d2b831afeb1f6 /src/testdir/test_blockedit.vim | |
parent | b07bbb0d29493fcf4ed080fe018535e64441d663 (diff) | |
download | vim-git-35e802e713382d7e76232ad344af7dcd577e43de.tar.gz |
patch 8.0.1779: deleting in a block selection causes problemsv8.0.1779
Problem: Deleting in a block selection causes problems.
Solution: Check the length of the line before adding bd.textcol and
bd.textlen. (Christian Brabandt, closes #2825)
Diffstat (limited to 'src/testdir/test_blockedit.vim')
-rw-r--r-- | src/testdir/test_blockedit.vim | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/src/testdir/test_blockedit.vim b/src/testdir/test_blockedit.vim index 4a8d59952..527224ccd 100644 --- a/src/testdir/test_blockedit.vim +++ b/src/testdir/test_blockedit.vim @@ -16,5 +16,18 @@ func Test_blockinsert_indent() bwipe! endfunc +func Test_blockinsert_delete() + new + let _bs = &bs + set bs=2 + call setline(1, ['case Arg is ', ' when Name_Async,', ' when Name_Num_Gangs,', 'end if;']) + exe "norm! ggjVj\<c-v>$o$A\<bs>\<esc>" + "call feedkeys("Vj\<c-v>$o$A\<bs>\<esc>", 'ti') + call assert_equal(["case Arg is ", " when Name_Async", " when Name_Num_Gangs,", "end if;"], + \ getline(1,'$')) + " reset to sane state + let &bs = _bs + bwipe! +endfunc " vim: shiftwidth=2 sts=2 expandtab |