diff options
author | Erik Johnston <erik@matrix.org> | 2019-09-25 17:16:28 +0100 |
---|---|---|
committer | Erik Johnston <erik@matrix.org> | 2019-09-25 17:16:28 +0100 |
commit | d2bd0bc6b188cca8c85ec34c79a70596ec0e46b1 (patch) | |
tree | 15032c3b14c0c9e3e52db8cd5fa4a04d985f034e /tests/test_terms_auth.py | |
parent | Use if `is not None` (diff) | |
parent | Threepid validity checks on msisdns should not be dependent on 'threepid_beha... (diff) | |
download | synapse-d2bd0bc6b188cca8c85ec34c79a70596ec0e46b1.tar.xz |
Merge branch 'develop' of github.com:matrix-org/synapse into erikj/cleanup_user_ips
Diffstat (limited to 'tests/test_terms_auth.py')
-rw-r--r-- | tests/test_terms_auth.py | 24 |
1 files changed, 15 insertions, 9 deletions
diff --git a/tests/test_terms_auth.py b/tests/test_terms_auth.py index 52739fbabc..5ec5d2b358 100644 --- a/tests/test_terms_auth.py +++ b/tests/test_terms_auth.py @@ -28,6 +28,21 @@ from tests import unittest class TermsTestCase(unittest.HomeserverTestCase): servlets = [register_servlets] + def default_config(self, name="test"): + config = super().default_config(name) + config.update( + { + "public_baseurl": "https://example.org/", + "user_consent": { + "version": "1.0", + "policy_name": "My Cool Privacy Policy", + "template_dir": "/", + "require_at_registration": True, + }, + } + ) + return config + def prepare(self, reactor, clock, hs): self.clock = MemoryReactorClock() self.hs_clock = Clock(self.clock) @@ -35,17 +50,8 @@ class TermsTestCase(unittest.HomeserverTestCase): self.registration_handler = Mock() self.auth_handler = Mock() self.device_handler = Mock() - hs.config.enable_registration = True - hs.config.registrations_require_3pid = [] - hs.config.auto_join_rooms = [] - hs.config.enable_registration_captcha = False def test_ui_auth(self): - self.hs.config.user_consent_at_registration = True - self.hs.config.user_consent_policy_name = "My Cool Privacy Policy" - self.hs.config.public_baseurl = "https://example.org/" - self.hs.config.user_consent_version = "1.0" - # Do a UI auth request request, channel = self.make_request(b"POST", self.url, b"{}") self.render(request) |