Test fixes for 3.15 (GH-133599)

Followup to 942673ed19 (GH-133588)

* Update configure for Python 3.15

* Update magic number for 3.15

* Remove deprecated 'check_home' argument from sysconfig.is_python_build

* Add warningignore entries for Modules/_sqlite/clinic/connection.c.h

* Work around c-analyzer complaints about _testclinic deprecation tests

---------

Co-authored-by: Hugo van Kemenade <1324225+hugovk@users.noreply.github.com>
This commit is contained in:
Zachary Ware 2025-05-07 14:50:39 -05:00 committed by GitHub
parent 1460ccefd0
commit 74e2acddf6
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
10 changed files with 244 additions and 249 deletions

View file

@ -2985,7 +2985,7 @@ class ClinicFunctionalTest(unittest.TestCase):
regex = (
fr"Passing( more than)?( [0-9]+)? positional argument(s)? to "
fr"{re.escape(name)}\(\) is deprecated. Parameters? {pnames} will "
fr"become( a)? keyword-only parameters? in Python 3\.14"
fr"become( a)? keyword-only parameters? in Python 3\.37"
)
self.check_depr(regex, fn, *args, **kwds)
@ -2998,7 +2998,7 @@ class ClinicFunctionalTest(unittest.TestCase):
regex = (
fr"Passing keyword argument{pl} {pnames} to "
fr"{re.escape(name)}\(\) is deprecated. Parameter{pl} {pnames} "
fr"will become positional-only in Python 3\.14."
fr"will become positional-only in Python 3\.37."
)
self.check_depr(regex, fn, *args, **kwds)
@ -3782,9 +3782,9 @@ class ClinicFunctionalTest(unittest.TestCase):
fn("a", b="b", c="c", d="d", e="e", f="f", g="g", h="h")
errmsg = (
"Passing more than 1 positional argument to depr_star_multi() is deprecated. "
"Parameter 'b' will become a keyword-only parameter in Python 3.16. "
"Parameters 'c' and 'd' will become keyword-only parameters in Python 3.15. "
"Parameters 'e', 'f' and 'g' will become keyword-only parameters in Python 3.14.")
"Parameter 'b' will become a keyword-only parameter in Python 3.39. "
"Parameters 'c' and 'd' will become keyword-only parameters in Python 3.38. "
"Parameters 'e', 'f' and 'g' will become keyword-only parameters in Python 3.37.")
check = partial(self.check_depr, re.escape(errmsg), fn)
check("a", "b", c="c", d="d", e="e", f="f", g="g", h="h")
check("a", "b", "c", d="d", e="e", f="f", g="g", h="h")
@ -3883,9 +3883,9 @@ class ClinicFunctionalTest(unittest.TestCase):
fn("a", "b", "c", "d", "e", "f", "g", h="h")
errmsg = (
"Passing keyword arguments 'b', 'c', 'd', 'e', 'f' and 'g' to depr_kwd_multi() is deprecated. "
"Parameter 'b' will become positional-only in Python 3.14. "
"Parameters 'c' and 'd' will become positional-only in Python 3.15. "
"Parameters 'e', 'f' and 'g' will become positional-only in Python 3.16.")
"Parameter 'b' will become positional-only in Python 3.37. "
"Parameters 'c' and 'd' will become positional-only in Python 3.38. "
"Parameters 'e', 'f' and 'g' will become positional-only in Python 3.39.")
check = partial(self.check_depr, re.escape(errmsg), fn)
check("a", "b", "c", "d", "e", "f", g="g", h="h")
check("a", "b", "c", "d", "e", f="f", g="g", h="h")
@ -3900,8 +3900,8 @@ class ClinicFunctionalTest(unittest.TestCase):
self.assertRaises(TypeError, fn, "a", "b", "c", "d", "e", "f", "g")
errmsg = (
"Passing more than 4 positional arguments to depr_multi() is deprecated. "
"Parameter 'e' will become a keyword-only parameter in Python 3.15. "
"Parameter 'f' will become a keyword-only parameter in Python 3.14.")
"Parameter 'e' will become a keyword-only parameter in Python 3.38. "
"Parameter 'f' will become a keyword-only parameter in Python 3.37.")
check = partial(self.check_depr, re.escape(errmsg), fn)
check("a", "b", "c", "d", "e", "f", g="g")
check("a", "b", "c", "d", "e", f="f", g="g")
@ -3909,8 +3909,8 @@ class ClinicFunctionalTest(unittest.TestCase):
fn("a", "b", "c", d="d", e="e", f="f", g="g")
errmsg = (
"Passing keyword arguments 'b' and 'c' to depr_multi() is deprecated. "
"Parameter 'b' will become positional-only in Python 3.14. "
"Parameter 'c' will become positional-only in Python 3.15.")
"Parameter 'b' will become positional-only in Python 3.37. "
"Parameter 'c' will become positional-only in Python 3.38.")
check = partial(self.check_depr, re.escape(errmsg), fn)
check("a", "b", c="c", d="d", e="e", f="f", g="g")
check("a", b="b", c="c", d="d", e="e", f="f", g="g")