fix (lots of) py3 test failures

This commit is contained in:
Neil Johnson 2018-08-03 14:59:17 +01:00
parent b2aab04d2c
commit 5593ff6773
3 changed files with 3 additions and 3 deletions

View File

@ -69,12 +69,12 @@ class ServerConfig(Config):
# Options to control access by tracking MAU
self.limit_usage_by_mau = config.get("limit_usage_by_mau", False)
self.max_mau_value = 0
if self.limit_usage_by_mau:
self.max_mau_value = config.get(
"max_mau_value", 0,
)
else:
self.max_mau_value = 0
# FIXME: federation_domain_whitelist needs sytests
self.federation_domain_whitelist = None
federation_domain_whitelist = config.get(

View File

@ -34,7 +34,6 @@ class ClientIpStoreTestCase(tests.unittest.TestCase):
@defer.inlineCallbacks
def test_insert_new_client_ip(self):
self.hs.config.max_mau_value = 50
self.clock.now = 12345678
user_id = "@user:id"
yield self.store.insert_client_ip(

View File

@ -73,6 +73,7 @@ def setup_test_homeserver(name="test", datastore=None, config=None, reactor=None
config.block_events_without_consent_error = None
config.media_storage_providers = []
config.auto_join_rooms = []
config.limit_usage_by_mau = False
# disable user directory updates, because they get done in the
# background, which upsets the test runner.