summary refs log tree commit diff
path: root/tests/util/caches/test_descriptors.py
diff options
context:
space:
mode:
authorAndrew Morgan <andrew@amorgan.xyz>2021-04-13 16:10:07 +0100
committerAndrew Morgan <andrew@amorgan.xyz>2021-04-13 16:10:07 +0100
commit77866a5f5f9e805ebe599a5dc7d19152b68a0f01 (patch)
treee81016df9807f97c1c8f88b82ad9c73cbaa94586 /tests/util/caches/test_descriptors.py
parentRevert "Patch to temporarily drop cross-user m.key_share_requests (#8675)" (diff)
parentMerge branch 'erikj/fix_stalled_catchup' into matrix-org-hotfixes (diff)
downloadsynapse-77866a5f5f9e805ebe599a5dc7d19152b68a0f01.tar.xz
Merge branch 'matrix-org-hotfixes' of github.com:matrix-org/synapse into matrix-org-hotfixes
Diffstat (limited to 'tests/util/caches/test_descriptors.py')
-rw-r--r--tests/util/caches/test_descriptors.py7
1 files changed, 3 insertions, 4 deletions
diff --git a/tests/util/caches/test_descriptors.py b/tests/util/caches/test_descriptors.py

index afb11b9caf..e434e21aee 100644 --- a/tests/util/caches/test_descriptors.py +++ b/tests/util/caches/test_descriptors.py
@@ -661,14 +661,13 @@ class CachedListDescriptorTestCase(unittest.TestCase): @descriptors.cachedList("fn", "args1") async def list_fn(self, args1, arg2): - assert current_context().request == "c1" + assert current_context().name == "c1" # we want this to behave like an asynchronous function await run_on_reactor() - assert current_context().request == "c1" + assert current_context().name == "c1" return self.mock(args1, arg2) - with LoggingContext() as c1: - c1.request = "c1" + with LoggingContext("c1") as c1: obj = Cls() obj.mock.return_value = {10: "fish", 20: "chips"} d1 = obj.list_fn([10, 20], 2)