comparison src/testdir/test_edit.vim @ 11315:0c091a7c588c v8.0.0543

patch 8.0.0543: test_edit causes older xfce4-terminal to close commit https://github.com/vim/vim/commit/ba6ec182973af726ce9b7b7eb3753fc3a7ae7d1b Author: Bram Moolenaar <Bram@vim.org> Date: Tue Apr 4 22:41:10 2017 +0200 patch 8.0.0543: test_edit causes older xfce4-terminal to close Problem: Test_edit causes older xfce4-terminal to close. (Dominique Pelle) Solution: Reduce number of columns to 2000. Try to restore the window position.
author Christian Brabandt <cb@256bit.org>
date Tue, 04 Apr 2017 22:45:05 +0200
parents cb2040d45876
children 2dc624388934
comparison
equal deleted inserted replaced
11314:2808577a0260 11315:0c091a7c588c
1326 func Test_edit_complete_very_long_name() 1326 func Test_edit_complete_very_long_name()
1327 if !has('unix') || has('mac') 1327 if !has('unix') || has('mac')
1328 " Long directory names only work on Unix. 1328 " Long directory names only work on Unix.
1329 return 1329 return
1330 endif 1330 endif
1331 " Try to get the Vim window position before setting 'columns'.
1332 let winposx = getwinposx()
1333 let winposy = getwinposy()
1331 let save_columns = &columns 1334 let save_columns = &columns
1332 set columns=5000 1335 set columns=2000
1333 call assert_equal(5000, &columns) 1336 call assert_equal(2000, &columns)
1334 set noswapfile 1337 set noswapfile
1338
1335 let dirname = getcwd() . "/Xdir" 1339 let dirname = getcwd() . "/Xdir"
1336 let longdirname = dirname . repeat('/' . repeat('d', 255), 4) 1340 let longdirname = dirname . repeat('/' . repeat('d', 255), 4)
1337 let longfilename = longdirname . '/' . repeat('a', 255) 1341 let longfilename = longdirname . '/' . repeat('a', 255)
1338 call mkdir(longdirname, 'p') 1342 call mkdir(longdirname, 'p')
1339 call writefile(['Totum', 'Table'], longfilename) 1343 call writefile(['Totum', 'Table'], longfilename)
1343 1347
1344 bwipe! 1348 bwipe!
1345 exe 'bwipe! ' . longfilename 1349 exe 'bwipe! ' . longfilename
1346 call delete(dirname, 'rf') 1350 call delete(dirname, 'rf')
1347 let &columns = save_columns 1351 let &columns = save_columns
1352 if winposx >= 0 && winposy >= 0
1353 exe 'winpos ' . winposx . ' ' . winposy
1354 endif
1348 set swapfile& 1355 set swapfile&
1349 endfunc 1356 endfunc