To: vim_dev@googlegroups.com Subject: Patch 8.2.0444 Fcc: outbox From: Bram Moolenaar Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ------------ Patch 8.2.0444 Problem: Swap file test fails on some systems. Solution: Preserve the swap file. Send NL terminated keys. Files: src/testdir/test_swap.vim *** ../vim-8.2.0443/src/testdir/test_swap.vim 2020-02-22 21:21:23.694595578 +0100 --- src/testdir/test_swap.vim 2020-03-24 21:37:28.008391721 +0100 *************** *** 1,5 **** --- 1,6 ---- " Tests for the swap feature + source check.vim source shared.vim source term_util.vim *************** *** 352,362 **** " Test for selecting 'q' in the attention prompt func Test_swap_prompt_splitwin() ! if !CanRunVimInTerminal() ! throw 'Skipped: cannot run vim in terminal' ! endif call writefile(['foo bar'], 'Xfile1') edit Xfile1 let buf = RunVimInTerminal('', {'rows': 20}) call term_sendkeys(buf, ":set nomore\n") call term_sendkeys(buf, ":set noruler\n") --- 353,364 ---- " Test for selecting 'q' in the attention prompt func Test_swap_prompt_splitwin() ! CheckRunVimInTerminal ! call writefile(['foo bar'], 'Xfile1') edit Xfile1 + preserve " should help to make sure the swap file exists + let buf = RunVimInTerminal('', {'rows': 20}) call term_sendkeys(buf, ":set nomore\n") call term_sendkeys(buf, ":set noruler\n") *************** *** 365,373 **** call WaitForAssert({-> assert_match('^\[O\]pen Read-Only, (E)dit anyway, (R)ecover, (Q)uit, (A)bort: $', term_getline(buf, 20))}) call term_sendkeys(buf, "q") call term_wait(buf) ! call term_sendkeys(buf, ":") call WaitForAssert({-> assert_match('^:$', term_getline(buf, 20))}) ! call term_sendkeys(buf, "echomsg winnr('$')\") call term_wait(buf) call WaitForAssert({-> assert_match('^1$', term_getline(buf, 20))}) call StopVimInTerminal(buf) --- 367,375 ---- call WaitForAssert({-> assert_match('^\[O\]pen Read-Only, (E)dit anyway, (R)ecover, (Q)uit, (A)bort: $', term_getline(buf, 20))}) call term_sendkeys(buf, "q") call term_wait(buf) ! call term_sendkeys(buf, ":\") call WaitForAssert({-> assert_match('^:$', term_getline(buf, 20))}) ! call term_sendkeys(buf, ":echomsg winnr('$')\") call term_wait(buf) call WaitForAssert({-> assert_match('^1$', term_getline(buf, 20))}) call StopVimInTerminal(buf) *** ../vim-8.2.0443/src/version.c 2020-03-24 21:41:38.031535404 +0100 --- src/version.c 2020-03-24 21:44:28.318955269 +0100 *************** *** 740,741 **** --- 740,743 ---- { /* Add new patch number below this line */ + /**/ + 444, /**/ -- ARTHUR: I did say sorry about the `old woman,' but from the behind you looked-- DENNIS: What I object to is you automatically treat me like an inferior! ARTHUR: Well, I AM king... The Quest for the Holy Grail (Monty Python) /// Bram Moolenaar -- Bram@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 ///