summary refs log tree commit diff
path: root/tests/util/test_threepids.py
diff options
context:
space:
mode:
authorMathieu Velten <mathieuv@matrix.org>2022-12-12 17:48:27 +0100
committerMathieu Velten <mathieuv@matrix.org>2022-12-12 17:48:27 +0100
commit4ccade636e9903c78eeba89d8487a3b3e2ba4e2f (patch)
tree8a8e732fceda8923054506689833eb447067e711 /tests/util/test_threepids.py
parentMerge remote-tracking branch 'origin/develop' into mv/unbind-callback (diff)
parentMove `StateFilter` to `synapse.types` (#14668) (diff)
downloadsynapse-4ccade636e9903c78eeba89d8487a3b3e2ba4e2f.tar.xz
Merge remote-tracking branch 'origin/develop' into mv/unbind-callback
Diffstat (limited to 'tests/util/test_threepids.py')
-rw-r--r--tests/util/test_threepids.py16
1 files changed, 8 insertions, 8 deletions
diff --git a/tests/util/test_threepids.py b/tests/util/test_threepids.py

index d957b953bb..3b35b8e4ec 100644 --- a/tests/util/test_threepids.py +++ b/tests/util/test_threepids.py
@@ -18,31 +18,31 @@ from tests.unittest import HomeserverTestCase class CanonicaliseEmailTests(HomeserverTestCase): - def test_no_at(self): + def test_no_at(self) -> None: with self.assertRaises(ValueError): canonicalise_email("address-without-at.bar") - def test_two_at(self): + def test_two_at(self) -> None: with self.assertRaises(ValueError): canonicalise_email("foo@foo@test.bar") - def test_bad_format(self): + def test_bad_format(self) -> None: with self.assertRaises(ValueError): canonicalise_email("user@bad.example.net@good.example.com") - def test_valid_format(self): + def test_valid_format(self) -> None: self.assertEqual(canonicalise_email("foo@test.bar"), "foo@test.bar") - def test_domain_to_lower(self): + def test_domain_to_lower(self) -> None: self.assertEqual(canonicalise_email("foo@TEST.BAR"), "foo@test.bar") - def test_domain_with_umlaut(self): + def test_domain_with_umlaut(self) -> None: self.assertEqual(canonicalise_email("foo@Öumlaut.com"), "foo@öumlaut.com") - def test_address_casefold(self): + def test_address_casefold(self) -> None: self.assertEqual( canonicalise_email("Strauß@Example.com"), "strauss@example.com" ) - def test_address_trim(self): + def test_address_trim(self) -> None: self.assertEqual(canonicalise_email(" foo@test.bar "), "foo@test.bar")