From: Victor Stinner Date: Tue, 5 Jul 2011 11:14:17 +0000 (+0200) Subject: test_array: make quiet the DeprecationWarning X-Git-Tag: v2.7.3rc1~635 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=42dcc679c2a6d434651c8a03f3a5a3bf0c62841b;p=thirdparty%2FPython%2Fcpython.git test_array: make quiet the DeprecationWarning --- diff --git a/Lib/test/test_array.py b/Lib/test/test_array.py index b6c0f1bdd589..acf5b8f81a5f 100755 --- a/Lib/test/test_array.py +++ b/Lib/test/test_array.py @@ -4,6 +4,7 @@ """ import unittest +import warnings from test import test_support from weakref import proxy import array, cStringIO @@ -783,7 +784,9 @@ class BaseTest(unittest.TestCase): def test_subclass_with_kwargs(self): # SF bug #1486663 -- this used to erroneously raise a TypeError - ArraySubclassWithKwargs('b', newarg=1) + with warnings.catch_warnings(): + warnings.filterwarnings("ignore", '', DeprecationWarning) + ArraySubclassWithKwargs('b', newarg=1) class StringTest(BaseTest):