From f5770f354cb982303237d581ad2b296486475965 Mon Sep 17 00:00:00 2001 From: Xtreak Date: Thu, 5 Jul 2018 22:29:46 +0530 Subject: [PATCH] bpo-33988: Fix test_warnings using -W error (GH-7985) Use DeprecationWarning instead of PendingDeprecationWarning. --- Lib/test/test_platform.py | 4 ++-- Lib/test/test_ssl.py | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/Lib/test/test_platform.py b/Lib/test/test_platform.py index 5f1e28a5d9..d3b77eb5a6 100644 --- a/Lib/test/test_platform.py +++ b/Lib/test/test_platform.py @@ -265,7 +265,7 @@ class PlatformTest(unittest.TestCase): 'ignore', r'dist\(\) and linux_distribution\(\) ' 'functions are deprecated .*', - PendingDeprecationWarning, + DeprecationWarning, ) res = platform.dist() @@ -341,7 +341,7 @@ class PlatformTest(unittest.TestCase): 'ignore', r'dist\(\) and linux_distribution\(\) ' 'functions are deprecated .*', - PendingDeprecationWarning, + DeprecationWarning, ) distname, version, distid = platform.linux_distribution() diff --git a/Lib/test/test_ssl.py b/Lib/test/test_ssl.py index 7bbaa9f1e8..d80e8d3fcf 100644 --- a/Lib/test/test_ssl.py +++ b/Lib/test/test_ssl.py @@ -4145,7 +4145,7 @@ def test_main(verbose=False): 'ignore', r'dist\(\) and linux_distribution\(\) ' 'functions are deprecated .*', - PendingDeprecationWarning, + DeprecationWarning, ) for name, func in plats.items(): plat = func() -- 2.50.1