mirror of
https://git.anonymousland.org/anonymousland/synapse.git
synced 2024-10-01 11:49:51 -04:00
Fix logcontext leak in test_url_preview
This commit is contained in:
parent
a267c2e3ed
commit
828f18bd8b
@ -20,6 +20,7 @@ from mock import Mock
|
|||||||
from twisted.internet.defer import Deferred
|
from twisted.internet.defer import Deferred
|
||||||
|
|
||||||
from synapse.config.repository import MediaStorageProviderConfig
|
from synapse.config.repository import MediaStorageProviderConfig
|
||||||
|
from synapse.util.logcontext import make_deferred_yieldable
|
||||||
from synapse.util.module_loader import load_module
|
from synapse.util.module_loader import load_module
|
||||||
|
|
||||||
from tests import unittest
|
from tests import unittest
|
||||||
@ -77,7 +78,7 @@ class URLPreviewTests(unittest.HomeserverTestCase):
|
|||||||
d = Deferred()
|
d = Deferred()
|
||||||
d.addCallback(write_to)
|
d.addCallback(write_to)
|
||||||
self.fetches.append((d, url))
|
self.fetches.append((d, url))
|
||||||
return d
|
return make_deferred_yieldable(d)
|
||||||
|
|
||||||
client = Mock()
|
client = Mock()
|
||||||
client.get_file = get_file
|
client.get_file = get_file
|
||||||
|
Loading…
Reference in New Issue
Block a user