summaryrefslogtreecommitdiff
path: root/Lib/test/test_functools.py
diff options
context:
space:
mode:
Diffstat (limited to 'Lib/test/test_functools.py')
-rw-r--r--Lib/test/test_functools.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/Lib/test/test_functools.py b/Lib/test/test_functools.py
index d04423777c..75ae7f3a15 100644
--- a/Lib/test/test_functools.py
+++ b/Lib/test/test_functools.py
@@ -1126,7 +1126,8 @@ class TestSingleDispatch(unittest.TestCase):
"Simple test"
return "Test"
self.assertEqual(g.__name__, "g")
- self.assertEqual(g.__doc__, "Simple test")
+ if sys.flags.optimize < 2:
+ self.assertEqual(g.__doc__, "Simple test")
@unittest.skipUnless(decimal, 'requires _decimal')
@support.cpython_only