mirror of
https://github.com/python/cpython.git
synced 2025-07-24 11:44:31 +00:00
gh-119011: type.__type_params__
now return an empty tuple (#119296)
This commit is contained in:
parent
ae11d68ab9
commit
6b240c2308
4 changed files with 19 additions and 0 deletions
|
@ -710,6 +710,14 @@ class TestUpdateWrapper(unittest.TestCase):
|
|||
self.assertTrue(wrapper.__doc__.startswith('max('))
|
||||
self.assertEqual(wrapper.__annotations__, {})
|
||||
|
||||
def test_update_type_wrapper(self):
|
||||
def wrapper(*args): pass
|
||||
|
||||
functools.update_wrapper(wrapper, type)
|
||||
self.assertEqual(wrapper.__name__, 'type')
|
||||
self.assertEqual(wrapper.__annotations__, {})
|
||||
self.assertEqual(wrapper.__type_params__, ())
|
||||
|
||||
|
||||
class TestWraps(TestUpdateWrapper):
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue