0
0
mirror of https://github.com/vim/vim.git synced 2025-09-26 04:04:07 -04:00

patch 8.1.1166: gettitle test can still fail when another Vim is running

Problem:    Gettitle test can still fail when another Vim is running.
Solution:   Accept any server name number. (Dominique Pelle, closes #4252)
This commit is contained in:
Bram Moolenaar
2019-04-13 20:39:15 +02:00
parent ca57ab54d7
commit 9c35d05f45
2 changed files with 7 additions and 4 deletions

View File

@@ -1904,13 +1904,14 @@ func Test_term_gettitle()
let term = term_start([GetVimProg(), '--clean', '-c', 'set noswapfile'])
if has('autoservername')
call WaitForAssert({-> assert_equal('[No Name] - VIM1', term_gettitle(term)) })
call WaitForAssert({-> assert_match('^\[No Name\] - VIM\d\+$', term_gettitle(term)) })
call term_sendkeys(term, ":e Xfoo\r")
call WaitForAssert({-> assert_match('^Xfoo (.*[/\\]testdir) - VIM\d\+$', term_gettitle(term)) })
else
call WaitForAssert({-> assert_equal('[No Name] - VIM', term_gettitle(term)) })
endif
call term_sendkeys(term, ":e Xfoo\r")
call WaitForAssert({-> assert_match('Xfoo (.*[/\\]testdir) - VIM', term_gettitle(term)) })
call WaitForAssert({-> assert_match('^Xfoo (.*[/\\]testdir) - VIM$', term_gettitle(term)) })
endif
call term_sendkeys(term, ":set titlestring=foo\r")
call WaitForAssert({-> assert_equal('foo', term_gettitle(term)) })

View File

@@ -771,6 +771,8 @@ static char *(features[]) =
static int included_patches[] =
{ /* Add new patch number below this line */
/**/
1166,
/**/
1165,
/**/