comparison src/testdir/test_startup.vim @ 29247:5f314b2ed494 v8.2.5142

patch 8.2.5142: startup test fails if there is a status bar Commit: https://github.com/vim/vim/commit/fa04eae5a5b9394079bde2d37ce6f9f8a5567d48 Author: Bram Moolenaar <Bram@vim.org> Date: Tue Jun 21 14:38:40 2022 +0100 patch 8.2.5142: startup test fails if there is a status bar Problem: Startup test fails if there is a status bar at the top of the screen. (Ernie Rael) Solution: Use a larger vertical offset in the test.
author Bram Moolenaar <Bram@vim.org>
date Tue, 21 Jun 2022 18:45:07 +0200
parents 0533e7466ef0
children d891115c0aea
comparison
equal deleted inserted replaced
29246:3415983cabfb 29247:5f314b2ed494
529 else 529 else
530 let after =<< trim [CODE] 530 let after =<< trim [CODE]
531 call writefile([&columns, &lines, getwinposx(), getwinposy(), string(getwinpos())], "Xtest_geometry") 531 call writefile([&columns, &lines, getwinposx(), getwinposy(), string(getwinpos())], "Xtest_geometry")
532 qall 532 qall
533 [CODE] 533 [CODE]
534 if RunVim([], after, '-f -g -geometry 31x13+41+43') 534 " Some window managers have a bar at the top that pushes windows down,
535 " need to use at least 130, let's do 150
536 if RunVim([], after, '-f -g -geometry 31x13+41+150')
535 let lines = readfile('Xtest_geometry') 537 let lines = readfile('Xtest_geometry')
536 " Depending on the GUI library and the windowing system the final size 538 " Depending on the GUI library and the windowing system the final size
537 " might be a bit different, allow for some tolerance. Tuned based on 539 " might be a bit different, allow for some tolerance. Tuned based on
538 " actual failures. 540 " actual failures.
539 call assert_inrange(31, 35, str2nr(lines[0])) 541 call assert_inrange(31, 35, str2nr(lines[0]))
540 call assert_equal('13', lines[1]) 542 call assert_equal('13', lines[1])
541 call assert_equal('41', lines[2]) 543 call assert_equal('41', lines[2])
542 call assert_equal('43', lines[3]) 544 call assert_equal('150', lines[3])
543 call assert_equal('[41, 43]', lines[4]) 545 call assert_equal('[41, 150]', lines[4])
544 endif 546 endif
545 endif 547 endif
546 548
547 call delete('Xtest_geometry') 549 call delete('Xtest_geometry')
548 endfunc 550 endfunc