We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 35a90f3 commit 2a0637eCopy full SHA for 2a0637e
tests/unit/mcpgateway/cache/test_resource_cache.py
@@ -10,6 +10,7 @@
10
11
# Standard
12
import asyncio
13
+import logging
14
import time
15
16
# Third-Party
@@ -40,11 +41,11 @@ def test_expiration(cache):
40
41
"""Test that cache entry expires after TTL."""
42
# Use a more generous sleep duration to account for timing variability
43
cache.set("foo", "bar")
-
44
+
45
# Sleep for 1.5 seconds (50% longer than TTL) to ensure expiration
46
# This accounts for system load, clock precision, and floating point issues
47
time.sleep(1.5)
48
49
# Entry should definitely be expired now
50
assert cache.get("foo") is None
51
0 commit comments