From e81a6c86c89da02a0da719926198ab72edab2e05 Mon Sep 17 00:00:00 2001 From: "Miss Islington (bot)" <31488909+miss-islington@users.noreply.github.com> Date: Tue, 13 Feb 2018 07:07:34 -0800 Subject: [PATCH] bpo-31787: Skip refleak check when _hashlib is not available (GH-5660) (cherry picked from commit f0bc645dfede8118c84844bad319cd952c4d1905) Co-authored-by: INADA Naoki --- Lib/test/test_hashlib.py | 1 + 1 file changed, 1 insertion(+) diff --git a/Lib/test/test_hashlib.py b/Lib/test/test_hashlib.py index f7df872793c..5b0218b0856 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')