diff options
Diffstat (limited to 'src/testdir/test_options.vim')
-rw-r--r-- | src/testdir/test_options.vim | 68 |
1 files changed, 68 insertions, 0 deletions
diff --git a/src/testdir/test_options.vim b/src/testdir/test_options.vim index 37dc201..fbfbaae 100644 --- a/src/testdir/test_options.vim +++ b/src/testdir/test_options.vim @@ -1293,6 +1293,44 @@ func Test_shortmess_F2() call assert_fails('call test_getvalue("abc")', 'E475:') endfunc +func Test_shortmess_F3() + call writefile(['foo'], 'X_dummy', 'D') + + set hidden + set autoread + e X_dummy + e Xotherfile + call assert_equal(['foo'], getbufline('X_dummy', 1, '$')) + set shortmess+=F + echo '' + + if has('nanotime') + sleep 10m + else + sleep 2 + endif + call writefile(['bar'], 'X_dummy') + bprev + call assert_equal('', Screenline(&lines)) + call assert_equal(['bar'], getbufline('X_dummy', 1, '$')) + + if has('nanotime') + sleep 10m + else + sleep 2 + endif + call writefile(['baz'], 'X_dummy') + checktime + call assert_equal('', Screenline(&lines)) + call assert_equal(['baz'], getbufline('X_dummy', 1, '$')) + + set shortmess& + set autoread& + set hidden& + bwipe X_dummy + bwipe Xotherfile +endfunc + func Test_local_scrolloff() set so=5 set siso=7 @@ -2234,4 +2272,34 @@ func Test_set_wrap() set wrap& smoothscroll& scrolloff& endfunc +func Test_delcombine() + new + set backspace=indent,eol,start + + set delcombine + call setline(1, 'β̳̈:β̳̈') + normal! 0x + call assert_equal('β̈:β̳̈', getline(1)) + exe "normal! A\<BS>" + call assert_equal('β̈:β̈', getline(1)) + normal! 0x + call assert_equal('β:β̈', getline(1)) + exe "normal! A\<BS>" + call assert_equal('β:β', getline(1)) + normal! 0x + call assert_equal(':β', getline(1)) + exe "normal! A\<BS>" + call assert_equal(':', getline(1)) + + set nodelcombine + call setline(1, 'β̳̈:β̳̈') + normal! 0x + call assert_equal(':β̳̈', getline(1)) + exe "normal! A\<BS>" + call assert_equal(':', getline(1)) + + set backspace& delcombine& + bwipe! +endfunc + " vim: shiftwidth=2 sts=2 expandtab |