patch 9.2.0125: tests: test_textformat.vim leaves swapfiles behind
Commit:
https://github.com/vim/vim/commit/271f4fe47bbf56b8224583e70e51aa6833509164
Author: Christian Brabandt <[email protected]>
Date: Sun Mar 8 20:32:13 2026 +0000
patch 9.2.0125: tests: test_textformat.vim leaves swapfiles behind
Problem: tests: test_textformat.vim leaves swapfiles behind
Solution: Close open buffer using :bw! instead of :close!
Signed-off-by: Christian Brabandt <[email protected]>
diff --git a/src/testdir/test_textformat.vim b/src/testdir/test_textformat.vim
index 91fe943c1..b61ccfce2 100644
--- a/src/testdir/test_textformat.vim
+++ b/src/testdir/test_textformat.vim
@@ -621,7 +621,7 @@ func Test_format_align()
right
setlocal norightleft
call assert_equal("Vim", getline(1))
- close!
+ bw!
endif
set tw&
@@ -1031,7 +1031,7 @@ func Test_mps_latin1()
normal %
call assert_equal(4, col('.'))
let &encoding = save_enc
- close!
+ bw!
endfunc
func Test_empty_matchpairs()
@@ -1196,7 +1196,7 @@ func Test_visual_gq_format()
redraw!
normal gq
setl textwidth&
- close!
+ bw!
endfunc
" Test for 'n' flag in 'formatoptions' to format numbered lists
@@ -1209,7 +1209,7 @@ func Test_fo_n()
normal gggqG
call assert_equal([' 1) one two', ' three', ' four', ' 2) two'],
\ getline(1, '$'))
- close!
+ bw!
endfunc
" Test for 'formatlistpat' option
@@ -1223,7 +1223,7 @@ func Test_formatlistpat()
normal gggqG
call assert_equal([' - one', ' two', ' three', ' - two'],
\ getline(1, '$'))
- close!
+ bw!
endfunc
" Test for the 'b' and 'v' flags in 'formatoptions'
@@ -1256,7 +1256,7 @@ func Test_fo_b()
call feedkeys('Amore five', 'xt')
call assert_equal(['one two three fourmore', 'five'], getline(1, '$'))
- close!
+ bw!
endfunc
" Test for the '1' flag in 'formatoptions'. Don't wrap text after a one letter
@@ -1276,7 +1276,7 @@ func Test_fo_1()
call feedkeys('A a bird', 'xt')
call assert_equal(['one two three four', 'a bird'], getline(1, '$'))
- close!
+ bw!
endfunc
" Test for 'l' flag in 'formatoptions'. When starting insert mode, if a line
@@ -1296,7 +1296,7 @@ func Test_fo_l()
call feedkeys('A six', 'xt')
call assert_equal(['one two three four five six'], getline(1, '$'))
- close!
+ bw!
endfunc
" Test for the '2' flag in 'formatoptions'
@@ -1312,7 +1312,7 @@ func Test_fo_2()
call assert_equal([" first line of a",
\ "paragraph. second line of the",
\ "same paragraph. third line."], getline(1, '$'))
- close!
+ bw!
endfunc
" This was leaving the cursor after the end of a line. Complicated way to
diff --git a/src/version.c b/src/version.c
index 5b78d544e..f745f3a7d 100644
--- a/src/version.c
+++ b/src/version.c
@@ -734,6 +734,8 @@ static char *(features[]) =
static int included_patches[] =
{ /* Add new patch number below this line */
+/**/
+ 125,
/**/
124,
/**/
--
--
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 visit
https://groups.google.com/d/msgid/vim_dev/E1vzKzn-00DLMk-Md%40256bit.org.