diff options
Diffstat (limited to 'Lib/test')
-rw-r--r-- | Lib/test/test_cookie.py | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/Lib/test/test_cookie.py b/Lib/test/test_cookie.py index 1fb9b7db9f..816133e497 100644 --- a/Lib/test/test_cookie.py +++ b/Lib/test/test_cookie.py @@ -90,9 +90,10 @@ class CookieTests(unittest.TestCase): def test_main(): run_unittest(CookieTests) - with check_warnings(('.+Cookie class is insecure; do not use it', - DeprecationWarning)): - run_doctest(Cookie) + if Cookie.__doc__ is not None: + with check_warnings(('.+Cookie class is insecure; do not use it', + DeprecationWarning)): + run_doctest(Cookie) if __name__ == '__main__': test_main() |