patch 9.1.1312: tests: Test_backupskip() fails when HOME is defined

Commit: 
https://github.com/vim/vim/commit/ad503fe92772cb37d6f8601f48ff2bdb34cdbe96
Author: Christian Brabandt <c...@256bit.org>
Date:   Wed Apr 16 20:25:47 2025 +0200

    patch 9.1.1312: tests: Test_backupskip() fails when HOME is defined
    
    Problem:  tests: Test_backupskip() fails when HOME is defined
    Solution: unset $HOME temporarily
    
    Signed-off-by: Christian Brabandt <c...@256bit.org>

diff --git a/src/testdir/test_options.vim b/src/testdir/test_options.vim
index d8ad3f210..9708fcc05 100644
--- a/src/testdir/test_options.vim
+++ b/src/testdir/test_options.vim
@@ -1168,11 +1168,14 @@ func Test_backupskip()
     call setenv(var, '/duplicate/path')
   endfor
 
+  " unset $HOME, so that it won't try to read init files
+  let saveenv['HOME'] = getenv("HOME")
+  call setenv('HOME', v:null)
   exe 'silent !' . cmd
   call assert_equal(['errors:'], readfile('Xtestout'))
 
   " restore environment variables
-  for var in ['TMPDIR', 'TMP', 'TEMP']
+  for var in ['TMPDIR', 'TMP', 'TEMP', 'HOME']
     call setenv(var, saveenv[var])
   endfor
 
diff --git a/src/version.c b/src/version.c
index 7aae2b508..2a51b4207 100644
--- a/src/version.c
+++ b/src/version.c
@@ -704,6 +704,8 @@ static char *(features[]) =
 
 static int included_patches[] =
 {   /* Add new patch number below this line */
+/**/
+    1312,
 /**/
     1311,
 /**/

-- 
-- 
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 vim_dev+unsubscr...@googlegroups.com.
To view this discussion visit 
https://groups.google.com/d/msgid/vim_dev/E1u57WO-006xiC-DA%40256bit.org.

Raspunde prin e-mail lui