Skip to content

Commit 3aa9621

Browse files
[3.11] gh-115249: Fix test_descr with -OO mode (GH-115250) (#115278)
gh-115249: Fix `test_descr` with `-OO` mode (GH-115250) (cherry picked from commit 1f23837) Co-authored-by: Nikita Sobolev <[email protected]>
1 parent 7f2a19e commit 3aa9621

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

Lib/test/test_descr.py

+5-1
Original file line numberDiff line numberDiff line change
@@ -1587,7 +1587,11 @@ def f(cls, arg):
15871587

15881588
cm = classmethod(f)
15891589
cm_dict = {'__annotations__': {},
1590-
'__doc__': "f docstring",
1590+
'__doc__': (
1591+
"f docstring"
1592+
if support.HAVE_DOCSTRINGS
1593+
else None
1594+
),
15911595
'__module__': __name__,
15921596
'__name__': 'f',
15931597
'__qualname__': f.__qualname__}

0 commit comments

Comments
 (0)