From: INADA Naoki Date: Tue, 13 Feb 2018 14:41:19 +0000 (+0900) Subject: bpo-31787: Skip refleak check when _hashlib is not available (GH-5660) X-Git-Tag: v3.8.0a1~2227 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=f0bc645dfede8118c84844bad319cd952c4d1905;p=python bpo-31787: Skip refleak check when _hashlib is not available (GH-5660) --- diff --git a/Lib/test/test_hashlib.py b/Lib/test/test_hashlib.py index f7df872793..5b0218b085 100644 --- a/Lib/test/test_hashlib.py +++ b/Lib/test/test_hashlib.py @@ -163,6 +163,7 @@ class HashLibTestCase(unittest.TestCase): return itertools.chain.from_iterable(constructors) @support.refcount_test + @unittest.skipIf(c_hashlib is None, 'Require _hashlib module') def test_refleaks_in_hash___init__(self): gettotalrefcount = support.get_attribute(sys, 'gettotalrefcount') sha1_hash = c_hashlib.new('sha1')