mirror of
https://git.anonymousland.org/anonymousland/synapse.git
synced 2025-05-02 10:56:06 -04:00
Factor out some of the common homeserver setup code into a
setup_test_homeserver function in utils.
This commit is contained in:
parent
ba63b4be5d
commit
896253e085
25 changed files with 140 additions and 360 deletions
|
@ -17,23 +17,17 @@
|
|||
from tests import unittest
|
||||
from twisted.internet import defer
|
||||
|
||||
from synapse.server import HomeServer
|
||||
from synapse.storage.profile import ProfileStore
|
||||
from synapse.types import UserID
|
||||
|
||||
from tests.utils import SQLiteMemoryDbPool
|
||||
from tests.utils import setup_test_homeserver
|
||||
|
||||
|
||||
class ProfileStoreTestCase(unittest.TestCase):
|
||||
|
||||
@defer.inlineCallbacks
|
||||
def setUp(self):
|
||||
db_pool = SQLiteMemoryDbPool()
|
||||
yield db_pool.prepare()
|
||||
|
||||
hs = HomeServer("test",
|
||||
db_pool=db_pool,
|
||||
)
|
||||
hs = yield setup_test_homeserver()
|
||||
|
||||
self.store = ProfileStore(hs)
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue