From 934cfc8f97f460c119e989c1396a710c124d52c2 Mon Sep 17 00:00:00 2001 From: Tomas R Date: Sun, 16 Feb 2025 14:34:54 +0100 Subject: [PATCH] gh-130185: Fix unintentionally skipped tests in `test_functools` (GH-130186) (cherry picked from commit 73d03005b028eb6e4d1a643f3ca7a1f5ff2040fc) Co-authored-by: Tomas R. --- Lib/test/test_functools.py | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/Lib/test/test_functools.py b/Lib/test/test_functools.py index dadcd04394b390..2a65b2cca5c78e 100644 --- a/Lib/test/test_functools.py +++ b/Lib/test/test_functools.py @@ -1313,6 +1313,16 @@ def fib(n): self.module._CacheInfo(hits=0, misses=0, maxsize=None, currsize=0)) +class TestCachePy(TestCache, unittest.TestCase): + module = py_functools + + +@unittest.skipUnless(c_functools, 'requires the C _functools module') +class TestCacheC(TestCache, unittest.TestCase): + if c_functools: + module = c_functools + + class TestLRU: def test_lru(self):