summary refs log tree commit diff
path: root/tests/utils.py
diff options
context:
space:
mode:
authorAmber Brown <hawkowl@atleastfornow.net>2018-08-18 01:08:45 +1000
committerGitHub <noreply@github.com>2018-08-18 01:08:45 +1000
commitc334ca67bb89039b3a00b7c9a1ce610e99859653 (patch)
treebc70fc575b225a0cd25694bbd371f3c78bea3b43 /tests/utils.py
parentRemove v1/register's broken shared secret functionality (#3703) (diff)
downloadsynapse-c334ca67bb89039b3a00b7c9a1ce610e99859653.tar.xz
Integrate presence from hotfixes (#3694)
Diffstat (limited to '')
-rw-r--r--tests/utils.py7
1 files changed, 4 insertions, 3 deletions
diff --git a/tests/utils.py b/tests/utils.py
index 6f8b1de3e7..bb0fc74054 100644
--- a/tests/utils.py
+++ b/tests/utils.py
@@ -93,7 +93,8 @@ def setupdb():
 
 @defer.inlineCallbacks
 def setup_test_homeserver(
-    cleanup_func, name="test", datastore=None, config=None, reactor=None, **kargs
+    cleanup_func, name="test", datastore=None, config=None, reactor=None,
+    homeserverToUse=HomeServer, **kargs
 ):
     """
     Setup a homeserver suitable for running tests against.  Keyword arguments
@@ -192,7 +193,7 @@ def setup_test_homeserver(
     config.database_config["args"]["cp_openfun"] = db_engine.on_new_connection
 
     if datastore is None:
-        hs = HomeServer(
+        hs = homeserverToUse(
             name,
             config=config,
             db_config=config.database_config,
@@ -235,7 +236,7 @@ def setup_test_homeserver(
 
         hs.setup()
     else:
-        hs = HomeServer(
+        hs = homeserverToUse(
             name,
             db_pool=None,
             datastore=datastore,