mirror of
https://github.com/python/cpython.git
synced 2025-09-26 10:19:53 +00:00
[3.12] gh-81682: Fix test failures when CPython is built without docstrings (GH-113410) (GH-113429)
(cherry picked from commit 4e5b27e6a3
)
This commit is contained in:
parent
fee2bc15f9
commit
fc4d2c3dc6
12 changed files with 43 additions and 16 deletions
|
@ -953,11 +953,12 @@ class CoroutineTest(unittest.TestCase):
|
|||
|
||||
def test_corotype_1(self):
|
||||
ct = types.CoroutineType
|
||||
self.assertIn('into coroutine', ct.send.__doc__)
|
||||
self.assertIn('inside coroutine', ct.close.__doc__)
|
||||
self.assertIn('in coroutine', ct.throw.__doc__)
|
||||
self.assertIn('of the coroutine', ct.__dict__['__name__'].__doc__)
|
||||
self.assertIn('of the coroutine', ct.__dict__['__qualname__'].__doc__)
|
||||
if not support.MISSING_C_DOCSTRINGS:
|
||||
self.assertIn('into coroutine', ct.send.__doc__)
|
||||
self.assertIn('inside coroutine', ct.close.__doc__)
|
||||
self.assertIn('in coroutine', ct.throw.__doc__)
|
||||
self.assertIn('of the coroutine', ct.__dict__['__name__'].__doc__)
|
||||
self.assertIn('of the coroutine', ct.__dict__['__qualname__'].__doc__)
|
||||
self.assertEqual(ct.__name__, 'coroutine')
|
||||
|
||||
async def f(): pass
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue