Patch 8.2.2016

5 views
Skip to first unread message

Bram Moolenaar

unread,
Nov 19, 2020, 12:58:43 PM11/19/20
to vim...@googlegroups.com

Patch 8.2.2016
Problem: Swap file test is a little flaky.
Solution: Don't set a byte to a fixed value, increment it.
Files: src/testdir/test_swap.vim


*** ../vim-8.2.2015/src/testdir/test_swap.vim 2020-11-09 21:04:12.203986366 +0100
--- src/testdir/test_swap.vim 2020-11-19 18:56:50.315763866 +0100
***************
*** 417,423 ****
" swap file should be automatically deleted.
bwipe!
" change the process ID to avoid the "still running" warning
! let swapfile_bytes[24] = 0x99
call writefile(swapfile_bytes, swapfile_name)
edit Xtest.scr
" will end up using the same swap file after deleting the existing one
--- 417,423 ----
" swap file should be automatically deleted.
bwipe!
" change the process ID to avoid the "still running" warning
! let swapfile_bytes[24] = swapfile_bytes[24] + 1
call writefile(swapfile_bytes, swapfile_name)
edit Xtest.scr
" will end up using the same swap file after deleting the existing one
***************
*** 433,439 ****
augroup END

" change the host name
! let swapfile_bytes[28 + 40] = 0x89
call writefile(swapfile_bytes, swapfile_name)
edit Xtest.scr
call assert_equal(1, filereadable(swapfile_name))
--- 433,439 ----
augroup END

" change the host name
! let swapfile_bytes[28 + 40] = swapfile_bytes[28 + 40] + 2
call writefile(swapfile_bytes, swapfile_name)
edit Xtest.scr
call assert_equal(1, filereadable(swapfile_name))
*** ../vim-8.2.2015/src/version.c 2020-11-19 18:53:15.188492574 +0100
--- src/version.c 2020-11-19 18:54:38.836227052 +0100
***************
*** 752,753 ****
--- 752,755 ----
{ /* Add new patch number below this line */
+ /**/
+ 2016,
/**/

--
press CTRL-ALT-DEL for more information

/// Bram Moolenaar -- Br...@Moolenaar.net -- http://www.Moolenaar.net \\\
/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
\\\ an exciting new programming language -- http://www.Zimbu.org ///
\\\ help me help AIDS victims -- http://ICCF-Holland.org ///
Reply all
Reply to author
Forward
0 new messages