]> git.ipfire.org Git - thirdparty/vim.git/commitdiff
patch 9.0.1689: python 3.12 produces warnings and fails test v9.0.1689
authorZdenek Dohnal <zdohnal@redhat.com>
Fri, 11 Aug 2023 21:32:23 +0000 (23:32 +0200)
committerChristian Brabandt <cb@256bit.org>
Fri, 11 Aug 2023 21:32:23 +0000 (23:32 +0200)
Problem: python 3.12 produces warnings and fails test
Solution: Make use of raw strings in python3 tests

closes: #12765

Signed-off-by: Christian Brabandt <cb@256bit.org>
Co-authored-by: Zdenek Dohnal <zdohnal@redhat.com>
src/testdir/test_python3.vim
src/version.c

index b7140ee7bc577ec49a123f834fd49ccc46a3072b..e975cb61b9118575dfe5f1ed1439c1569ad7ac30 100644 (file)
@@ -22,10 +22,10 @@ func Test_AAA_python3_setup()
     import sys
     import re
 
-    py33_type_error_pattern = re.compile('^__call__\(\) takes (\d+) positional argument but (\d+) were given$')
+    py33_type_error_pattern = re.compile(r'^__call__\(\) takes (\d+) positional argument but (\d+) were given$')
     py37_exception_repr = re.compile(r'([^\(\),])(\)+)$')
-    py39_type_error_pattern = re.compile('\w+\.([^(]+\(\) takes)')
-    py310_type_error_pattern = re.compile('takes (\d+) positional argument but (\d+) were given')
+    py39_type_error_pattern = re.compile(r'\w+\.([^(]+\(\) takes)')
+    py310_type_error_pattern = re.compile(r'takes (\d+) positional argument but (\d+) were given')
 
     def emsg(ei):
       return ei[0].__name__ + ':' + repr(ei[1].args)
index 99f0013ee119709b19b80908fb9accfa736ac81f..54a43765e78f5479d2a6b62b7267bf3e19af1683 100644 (file)
@@ -695,6 +695,8 @@ static char *(features[]) =
 
 static int included_patches[] =
 {   /* Add new patch number below this line */
+/**/
+    1689,
 /**/
     1688,
 /**/