Skip to content

Commit 8fb1b47

Browse files
committed
patch 8.2.0310: autocmd test fails on a slow system
Problem: Autocmd test fails on a slow system. Solution: Adjust the expectations. (James McCoy, closes #5685)
1 parent b81f56f commit 8fb1b47

2 files changed

Lines changed: 9 additions & 5 deletions

File tree

src/testdir/test_autocmd.vim

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2245,17 +2245,19 @@ func Test_autocmd_SafeState()
22452245
call writefile(lines, 'XSafeState')
22462246
let buf = RunVimInTerminal('-S XSafeState', #{rows: 6})
22472247

2248-
" Sometimes we loop to handle an K_IGNORE
2248+
" Sometimes we loop to handle a K_IGNORE, SafeState may be trigered once or
2249+
" more often.
22492250
call term_sendkeys(buf, ":echo g:safe\<CR>")
2250-
call WaitForAssert({-> assert_match('^[12] ', term_getline(buf, 6))}, 1000)
2251+
call WaitForAssert({-> assert_match('^\d ', term_getline(buf, 6))}, 1000)
22512252

2253+
" SafeStateAgain should be invoked at least three times
22522254
call term_sendkeys(buf, ":echo g:again\<CR>")
2253-
call WaitForAssert({-> assert_match('^xxxx', term_getline(buf, 6))}, 1000)
2255+
call WaitForAssert({-> assert_match('^xxx', term_getline(buf, 6))}, 1000)
22542256

22552257
call term_sendkeys(buf, ":let g:again = ''\<CR>:call CallTimer()\<CR>")
2256-
call term_wait(buf, 50)
2258+
call term_wait(buf, 100)
22572259
call term_sendkeys(buf, ":\<CR>")
2258-
call term_wait(buf, 50)
2260+
call term_wait(buf, 100)
22592261
call term_sendkeys(buf, ":echo g:again\<CR>")
22602262
call WaitForAssert({-> assert_match('xtx', term_getline(buf, 6))}, 1000)
22612263

src/version.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -738,6 +738,8 @@ static char *(features[]) =
738738

739739
static int included_patches[] =
740740
{ /* Add new patch number below this line */
741+
/**/
742+
310,
741743
/**/
742744
309,
743745
/**/

0 commit comments

Comments
 (0)