mirror of
https://github.com/python/cpython.git
synced 2025-12-09 18:48:05 +00:00
[3.9] bpo-37116: Use PEP 570 syntax for positional-only parameters. (GH-12620)
Turn deprecation warnings added in 3.8 into TypeError.
This commit is contained in:
parent
6c01ebcc0d
commit
142566c028
30 changed files with 45 additions and 330 deletions
|
|
@ -603,9 +603,9 @@ class TestBaseExitStack:
|
|||
stack.callback(arg=1)
|
||||
with self.assertRaises(TypeError):
|
||||
self.exit_stack.callback(arg=2)
|
||||
with self.assertWarns(DeprecationWarning):
|
||||
with self.assertRaises(TypeError):
|
||||
stack.callback(callback=_exit, arg=3)
|
||||
self.assertEqual(result, [((), {'arg': 3})])
|
||||
self.assertEqual(result, [])
|
||||
|
||||
def test_push(self):
|
||||
exc_raised = ZeroDivisionError
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue