summary refs log tree commit diff
path: root/tests/util/caches/test_ttlcache.py
diff options
context:
space:
mode:
authorErik Johnston <erik@matrix.org>2019-08-14 09:53:33 +0100
committerGitHub <noreply@github.com>2019-08-14 09:53:33 +0100
commit09f6152a1153b0f3b5430d1f14eb3e7ee74317c3 (patch)
tree4ccf454c591786c350023988a66c50bc89220e9a /tests/util/caches/test_ttlcache.py
parent1.3.0rc1 (diff)
parentNewsfile (diff)
downloadsynapse-09f6152a1153b0f3b5430d1f14eb3e7ee74317c3.tar.xz
Merge pull request #5844 from matrix-org/erikj/retry_well_known_lookup
Retry well-known lookup before expiry. 
Diffstat (limited to 'tests/util/caches/test_ttlcache.py')
-rw-r--r--tests/util/caches/test_ttlcache.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/tests/util/caches/test_ttlcache.py b/tests/util/caches/test_ttlcache.py
index c94cbb662b..816795c136 100644
--- a/tests/util/caches/test_ttlcache.py
+++ b/tests/util/caches/test_ttlcache.py
@@ -36,7 +36,7 @@ class CacheTestCase(unittest.TestCase):
         self.assertTrue("one" in self.cache)
         self.assertEqual(self.cache.get("one"), "1")
         self.assertEqual(self.cache["one"], "1")
-        self.assertEqual(self.cache.get_with_expiry("one"), ("1", 110))
+        self.assertEqual(self.cache.get_with_expiry("one"), ("1", 110, 10))
         self.assertEqual(self.cache._metrics.hits, 3)
         self.assertEqual(self.cache._metrics.misses, 0)
 
@@ -77,7 +77,7 @@ class CacheTestCase(unittest.TestCase):
         self.assertEqual(self.cache["two"], "2")
         self.assertEqual(self.cache["three"], "3")
 
-        self.assertEqual(self.cache.get_with_expiry("two"), ("2", 120))
+        self.assertEqual(self.cache.get_with_expiry("two"), ("2", 120, 20))
 
         self.assertEqual(self.cache._metrics.hits, 5)
         self.assertEqual(self.cache._metrics.misses, 0)