patch 9.1.0841: tests: still preferring python2 over python3

Commit: 
https://github.com/vim/vim/commit/cef8ab2c75841cee1cd72266aa662fbe54fc0acc
Author: Yee Cheng Chin <ychin....@gmail.com>
Date:   Mon Nov 4 20:26:47 2024 +0100

    patch 9.1.0841: tests: still preferring python2 over python3
    
    Problem:  tests: still preferring python2 over python3
    Solution: prefer Python 3 when picking a Python program in Vim tests,
              by checking for the more specific python version first and
              only when python3 not found, check for the python binary
              (Yee Cheng Chin)
    
    Most OSes have Python 3 mapped to `python3` instead of `python`. Vim
    tests should prioritize using that instead of Python 2 in case that is
    still installed on the host system.
    
    closes: #15986
    
    Signed-off-by: Yee Cheng Chin <ychin....@gmail.com>
    Signed-off-by: Christian Brabandt <c...@256bit.org>

diff --git a/src/testdir/shared.vim b/src/testdir/shared.vim
index a9b422c30..8ae6fa021 100644
--- a/src/testdir/shared.vim
+++ b/src/testdir/shared.vim
@@ -25,10 +25,10 @@ func PythonProg()
     if !(has('job') || executable('pkill'))
       return ''
     endif
-    if executable('python')
-      let s:python = 'python'
-    elseif executable('python3')
+    if executable('python3')
       let s:python = 'python3'
+    elseif executable('python')
+      let s:python = 'python'
     else
       return ''
     end
diff --git a/src/version.c b/src/version.c
index d00d28085..3c18aa479 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 */
+/**/
+    841,
 /**/
     840,
 /**/

-- 
-- 
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/E1t830Z-00EEgh-V4%40256bit.org.

Raspunde prin e-mail lui