Patch 9.0.0428
Problem:    Autocmd test uses common file name.
Solution:   Use unique name to reduce flakiness.
Files:      src/testdir/test_autocmd.vim, src/testdir/test_startup.vim


*** ../vim-9.0.0427/src/testdir/test_autocmd.vim        2022-09-09 
15:08:05.309011220 +0100
--- src/testdir/test_autocmd.vim        2022-09-09 17:03:45.873876570 +0100
***************
*** 756,762 ****
      augroup END
  
      func WriteErrors()
!       call writefile([execute("messages")], "Xerrors")
      endfunc
      au VimLeave * call WriteErrors()
    [CODE]
--- 756,762 ----
      augroup END
  
      func WriteErrors()
!       call writefile([execute("messages")], "XerrorsBwipe")
      endfunc
      au VimLeave * call WriteErrors()
    [CODE]
***************
*** 764,774 ****
    call writefile(content, 'Xvimrc', 'D')
    call system(GetVimCommand('Xvimrc') .. ' --not-a-term --noplugins -S 
Session.vim -c cq')
    sleep 100m
!   let errors = join(readfile('Xerrors'))
    call assert_match('E814:', errors)
  
    set swapfile
!   for file in ['Session.vim', 'Xerrors']
      call delete(file)
    endfor
  endfunc
--- 764,774 ----
    call writefile(content, 'Xvimrc', 'D')
    call system(GetVimCommand('Xvimrc') .. ' --not-a-term --noplugins -S 
Session.vim -c cq')
    sleep 100m
!   let errors = join(readfile('XerrorsBwipe'))
    call assert_match('E814:', errors)
  
    set swapfile
!   for file in ['Session.vim', 'XerrorsBwipe']
      call delete(file)
    endfor
  endfunc
***************
*** 781,796 ****
        edit foo1
        au 
BufNew,BufAdd,BufWinEnter,BufEnter,BufLeave,BufWinLeave,BufUnload,VimEnter foo* 
ball
        edit foo2
!       call writefile(['OK'], 'Xerrors')
        qall
    [CODE]
  
    call writefile(content, 'XblastBall', 'D')
    call system(GetVimCommand() .. ' --clean -S XblastBall')
    sleep 100m
!   call assert_match('OK', readfile('Xerrors')->join())
  
!   call delete('Xerrors')
  endfunc
  
  " SEGV occurs in older versions.
--- 781,796 ----
        edit foo1
        au 
BufNew,BufAdd,BufWinEnter,BufEnter,BufLeave,BufWinLeave,BufUnload,VimEnter foo* 
ball
        edit foo2
!       call writefile(['OK'], 'XerrorsBlast')
        qall
    [CODE]
  
    call writefile(content, 'XblastBall', 'D')
    call system(GetVimCommand() .. ' --clean -S XblastBall')
    sleep 100m
!   call assert_match('OK', readfile('XerrorsBlast')->join())
  
!   call delete('XerrorsBlast')
  endfunc
  
  " SEGV occurs in older versions.
***************
*** 817,823 ****
      au SessionLoadPost * call DeleteInactiveBufs()
  
      func WriteErrors()
!       call writefile([execute("messages")], "Xerrors")
      endfunc
      au VimLeave * call WriteErrors()
    [CODE]
--- 817,823 ----
      au SessionLoadPost * call DeleteInactiveBufs()
  
      func WriteErrors()
!       call writefile([execute("messages")], "XerrorsPost")
      endfunc
      au VimLeave * call WriteErrors()
    [CODE]
***************
*** 825,837 ****
    call writefile(content, 'Xvimrc', 'D')
    call system(GetVimCommand('Xvimrc') .. ' --not-a-term --noplugins -S 
Session.vim -c cq')
    sleep 100m
!   let errors = join(readfile('Xerrors'))
    " This probably only ever matches on unix.
    call assert_notmatch('Caught deadly signal SEGV', errors)
    call assert_match('SessionLoadPost DONE', errors)
  
    set swapfile
!   for file in ['Session.vim', 'Xerrors']
      call delete(file)
    endfor
  endfunc
--- 825,837 ----
    call writefile(content, 'Xvimrc', 'D')
    call system(GetVimCommand('Xvimrc') .. ' --not-a-term --noplugins -S 
Session.vim -c cq')
    sleep 100m
!   let errors = join(readfile('XerrorsPost'))
    " This probably only ever matches on unix.
    call assert_notmatch('Caught deadly signal SEGV', errors)
    call assert_match('SessionLoadPost DONE', errors)
  
    set swapfile
!   for file in ['Session.vim', 'XerrorsPost']
      call delete(file)
    endfor
  endfunc
*** ../vim-9.0.0427/src/testdir/test_startup.vim        2022-08-29 
22:31:15.923685244 +0100
--- src/testdir/test_startup.vim        2022-09-09 17:07:54.933156853 +0100
***************
*** 306,314 ****
    call writefile(lines, 'Xbadfile.c')
  
    let after =<< trim [CODE]
!     call writefile([&errorfile, string(getpos("."))], "Xtestout")
      copen
!     w >> Xtestout
      qall
    [CODE]
  
--- 306,314 ----
    call writefile(lines, 'Xbadfile.c')
  
    let after =<< trim [CODE]
!     call writefile([&errorfile, string(getpos("."))], "XtestoutQarg")
      copen
!     w >> XtestoutQarg
      qall
    [CODE]
  
***************
*** 316,345 ****
    call assert_equal('errors.err', &errorfile)
    call writefile(["Xbadfile.c:4:12: error: expected ';' before '}' token"], 
'errors.err')
    if RunVim([], after, '-q')
!     let lines = readfile('Xtestout')
      call assert_equal(['errors.err',
        \              '[0, 4, 12, 0]',
        \              "Xbadfile.c|4 col 12| error: expected ';' before '}' 
token"],
        \             lines)
    endif
!   call delete('Xtestout')
    call delete('errors.err')
  
!   " Test with explicit argument '-q Xerrors' (with space).
!   call writefile(["Xbadfile.c:4:12: error: expected ';' before '}' token"], 
'Xerrors')
!   if RunVim([], after, '-q Xerrors')
!     let lines = readfile('Xtestout')
!     call assert_equal(['Xerrors',
        \              '[0, 4, 12, 0]',
        \              "Xbadfile.c|4 col 12| error: expected ';' before '}' 
token"],
        \             lines)
    endif
!   call delete('Xtestout')
  
!   " Test with explicit argument '-qXerrors' (without space).
!   if RunVim([], after, '-qXerrors')
!     let lines = readfile('Xtestout')
!     call assert_equal(['Xerrors',
        \              '[0, 4, 12, 0]',
        \              "Xbadfile.c|4 col 12| error: expected ';' before '}' 
token"],
        \             lines)
--- 316,345 ----
    call assert_equal('errors.err', &errorfile)
    call writefile(["Xbadfile.c:4:12: error: expected ';' before '}' token"], 
'errors.err')
    if RunVim([], after, '-q')
!     let lines = readfile('XtestoutQarg')
      call assert_equal(['errors.err',
        \              '[0, 4, 12, 0]',
        \              "Xbadfile.c|4 col 12| error: expected ';' before '}' 
token"],
        \             lines)
    endif
!   call delete('XtestoutQarg')
    call delete('errors.err')
  
!   " Test with explicit argument '-q XerrorsQarg' (with space).
!   call writefile(["Xbadfile.c:4:12: error: expected ';' before '}' token"], 
'XerrorsQarg')
!   if RunVim([], after, '-q XerrorsQarg')
!     let lines = readfile('XtestoutQarg')
!     call assert_equal(['XerrorsQarg',
        \              '[0, 4, 12, 0]',
        \              "Xbadfile.c|4 col 12| error: expected ';' before '}' 
token"],
        \             lines)
    endif
!   call delete('XtestoutQarg')
  
!   " Test with explicit argument '-qXerrorsQarg' (without space).
!   if RunVim([], after, '-qXerrorsQarg')
!     let lines = readfile('XtestoutQarg')
!     call assert_equal(['XerrorsQarg',
        \              '[0, 4, 12, 0]',
        \              "Xbadfile.c|4 col 12| error: expected ';' before '}' 
token"],
        \             lines)
***************
*** 350,357 ****
    call assert_equal(3, v:shell_error)
  
    call delete('Xbadfile.c')
!   call delete('Xtestout')
!   call delete('Xerrors')
  endfunc
  
  " Test the -V[N]{filename} argument to set the 'verbose' option to N
--- 350,357 ----
    call assert_equal(3, v:shell_error)
  
    call delete('Xbadfile.c')
!   call delete('XtestoutQarg')
!   call delete('XerrorsQarg')
  endfunc
  
  " Test the -V[N]{filename} argument to set the 'verbose' option to N
*** ../vim-9.0.0427/src/version.c       2022-09-09 16:10:23.462536073 +0100
--- src/version.c       2022-09-09 17:08:47.917006418 +0100
***************
*** 705,706 ****
--- 705,708 ----
  {   /* Add new patch number below this line */
+ /**/
+     428,
  /**/

-- 
My sister Cecilia opened a computer store in Hawaii.
She sells C shells by the seashore.

 /// Bram Moolenaar -- [email protected] -- http://www.Moolenaar.net   \\\
///                                                                      \\\
\\\        sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ ///
 \\\            help me help AIDS victims -- http://ICCF-Holland.org    ///

-- 
-- 
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

--- 
You received this message because you are subscribed to the Google Groups 
"vim_dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/vim_dev/20220909161008.7911E1C0CE4%40moolenaar.net.

Raspunde prin e-mail lui