aboutsummaryrefslogtreecommitdiff
path: root/test/old/testdir/test_display.vim
diff options
context:
space:
mode:
Diffstat (limited to 'test/old/testdir/test_display.vim')
-rw-r--r--test/old/testdir/test_display.vim27
1 files changed, 9 insertions, 18 deletions
diff --git a/test/old/testdir/test_display.vim b/test/old/testdir/test_display.vim
index a0bbf34df2..554caa19d6 100644
--- a/test/old/testdir/test_display.vim
+++ b/test/old/testdir/test_display.vim
@@ -79,7 +79,7 @@ func Test_scroll_without_region()
set t_cs=
set laststatus=2
END
- call writefile(lines, 'Xtestscroll')
+ call writefile(lines, 'Xtestscroll', 'D')
let buf = RunVimInTerminal('-S Xtestscroll', #{rows: 10})
call VerifyScreenDump(buf, 'Test_scroll_no_region_1', {})
@@ -103,11 +103,9 @@ func Test_scroll_without_region()
" clean up
call StopVimInTerminal(buf)
- call delete('Xtestscroll')
endfunc
func Test_display_listchars_precedes()
- set fillchars+=vert:\|
call NewWindow(10, 10)
" Need a physical line that wraps over the complete
" window size
@@ -174,14 +172,13 @@ func Test_scroll_CursorLineNr_update()
exe ":norm! o\<esc>110ia\<esc>"
END
let filename = 'Xdrawscreen'
- call writefile(lines, filename)
+ call writefile(lines, filename, 'D')
let buf = RunVimInTerminal('-S '.filename, #{rows: 5, cols: 50})
call term_sendkeys(buf, "k")
call VerifyScreenDump(buf, 'Test_winline_rnu', {})
" clean up
call StopVimInTerminal(buf)
- call delete(filename)
endfunc
" check a long file name does not result in the hit-enter prompt
@@ -189,28 +186,27 @@ func Test_edit_long_file_name()
CheckScreendump
let longName = 'x'->repeat(min([&columns, 255]))
- call writefile([], longName)
+ call writefile([], longName, 'D')
let buf = RunVimInTerminal('-N -u NONE ' .. longName, #{rows: 8})
call VerifyScreenDump(buf, 'Test_long_file_name_1', {})
" clean up
call StopVimInTerminal(buf)
- call delete(longName)
endfunc
func Test_unprintable_fileformats()
CheckScreendump
- call writefile(["unix\r", "two"], 'Xunix.txt')
- call writefile(["mac\r", "two"], 'Xmac.txt')
+ call writefile(["unix\r", "two"], 'Xunix.txt', 'D')
+ call writefile(["mac\r", "two"], 'Xmac.txt', 'D')
let lines =<< trim END
edit Xunix.txt
split Xmac.txt
edit ++ff=mac
END
let filename = 'Xunprintable'
- call writefile(lines, filename)
+ call writefile(lines, filename, 'D')
let buf = RunVimInTerminal('-S '.filename, #{rows: 9, cols: 50})
call VerifyScreenDump(buf, 'Test_display_unprintable_01', {})
call term_sendkeys(buf, "\<C-W>\<C-W>\<C-L>")
@@ -218,9 +214,6 @@ func Test_unprintable_fileformats()
" clean up
call StopVimInTerminal(buf)
- call delete('Xunix.txt')
- call delete('Xmac.txt')
- call delete(filename)
endfunc
" Test for scrolling that modifies buffer during visual block
@@ -299,19 +292,18 @@ func Test_display_scroll_update_visual()
call sign_place(2, 'bar', 'foo', bufnr(), { 'lnum': 1 })
autocmd CursorMoved * if getcurpos()[1] == 2 | call sign_unplace('bar', { 'id': 1 }) | endif
END
- call writefile(lines, 'XupdateVisual.vim')
+ call writefile(lines, 'XupdateVisual.vim', 'D')
let buf = RunVimInTerminal('-S XupdateVisual.vim', #{rows: 8, cols: 60})
call term_sendkeys(buf, "VG7kk")
call VerifyScreenDump(buf, 'Test_display_scroll_update_visual', {})
call StopVimInTerminal(buf)
- call delete('XupdateVisual.vim')
endfunc
" Test for 'eob' (EndOfBuffer) item in 'fillchars'
func Test_eob_fillchars()
- " default value (skipped)
+ " default value
" call assert_match('eob:\~', &fillchars)
" invalid values
call assert_fails(':set fillchars=eob:', 'E474:')
@@ -405,7 +397,7 @@ func Test_local_fillchars()
call setline(1, ['window 4']->repeat(3))
setlocal fillchars=stl:4,stlnc:d,vert:>,eob:o
END
- call writefile(lines, 'Xdisplayfillchars')
+ call writefile(lines, 'Xdisplayfillchars', 'D')
let buf = RunVimInTerminal('-S Xdisplayfillchars', #{rows: 12})
call VerifyScreenDump(buf, 'Test_display_fillchars_1', {})
@@ -413,7 +405,6 @@ func Test_local_fillchars()
call VerifyScreenDump(buf, 'Test_display_fillchars_2', {})
call StopVimInTerminal(buf)
- call delete('Xdisplayfillchars')
endfunc
func Test_display_linebreak_breakat()