summary refs log tree commit diff
path: root/tests/handlers
diff options
context:
space:
mode:
authorAndrew Morgan <1342360+anoadragon453@users.noreply.github.com>2019-03-21 15:07:28 +0000
committerGitHub <noreply@github.com>2019-03-21 15:07:28 +0000
commit7bef97dfb730eeacf4835fbdd9c5e360984fbb1e (patch)
tree39b1d7b9885c1e55c761bc74fb90e285330316f2 /tests/handlers
parentMerge pull request #4908 from matrix-org/erikj/block_peek_on_blocked_rooms (diff)
parentClean up backoff_on_404 and metehod calls (diff)
downloadsynapse-7bef97dfb730eeacf4835fbdd9c5e360984fbb1e.tar.xz
Remove trailing slashes from outbound federation requests and retry on 400 (#4840)
As per #3622, we remove trailing slashes from outbound federation requests. However, to ensure that we remain backwards compatible with previous versions of Synapse, if we receive a HTTP 400 with `M_UNRECOGNIZED`, then we are likely talking to an older version of Synapse in which case we retry with a trailing slash appended to the request path.
Diffstat (limited to 'tests/handlers')
-rw-r--r--tests/handlers/test_typing.py2
1 files changed, 2 insertions, 0 deletions
diff --git a/tests/handlers/test_typing.py b/tests/handlers/test_typing.py
index 13486930fb..7decb22933 100644
--- a/tests/handlers/test_typing.py
+++ b/tests/handlers/test_typing.py
@@ -192,6 +192,7 @@ class TypingNotificationsTestCase(unittest.HomeserverTestCase):
             json_data_callback=ANY,
             long_retries=True,
             backoff_on_404=True,
+            try_trailing_slash_on_400=True,
         )
 
     def test_started_typing_remote_recv(self):
@@ -269,6 +270,7 @@ class TypingNotificationsTestCase(unittest.HomeserverTestCase):
             json_data_callback=ANY,
             long_retries=True,
             backoff_on_404=True,
+            try_trailing_slash_on_400=True,
         )
 
         self.assertEquals(self.event_source.get_current_key(), 1)