summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorMaxime “pep” Buquet <pep@bouah.net>2022-03-18 16:11:07 +0100
committerMaxime “pep” Buquet <pep@bouah.net>2022-03-19 10:31:34 +0100
commit7222ade0dd252380fb158bb9b1ca1fefec3899a5 (patch)
tree4b9928e15715badc2e942d0ed7b390440c349b9b /tests
parent14a6c7801d8ecaabe69a1e28a26fb0755b5ee9dd (diff)
downloadslixmpp-7222ade0dd252380fb158bb9b1ca1fefec3899a5.tar.gz
slixmpp-7222ade0dd252380fb158bb9b1ca1fefec3899a5.tar.bz2
slixmpp-7222ade0dd252380fb158bb9b1ca1fefec3899a5.tar.xz
slixmpp-7222ade0dd252380fb158bb9b1ca1fefec3899a5.zip
xep_0454: Ensure format_url returns a str
Signed-off-by: Maxime “pep” Buquet <pep@bouah.net>
Diffstat (limited to 'tests')
-rw-r--r--tests/test_xep_0454.py6
1 files changed, 6 insertions, 0 deletions
diff --git a/tests/test_xep_0454.py b/tests/test_xep_0454.py
index 3d0860a9..8d43c7e3 100644
--- a/tests/test_xep_0454.py
+++ b/tests/test_xep_0454.py
@@ -32,4 +32,10 @@ class TestMediaSharing(SlixTest):
self.assertEqual(plain, result)
+ def testFormatURL(self):
+ url = 'https://foo.bar'
+ fragment = 'a' * 88
+ result = XEP_0454.format_url(url, fragment)
+ self.assertEqual('aesgcm://foo.bar#' + 'a' * 88, result)
+
suite = unittest.TestLoader().loadTestsFromTestCase(TestMediaSharing)