about summary refs log tree commit diff
path: root/tst/test_listen.py
diff options
context:
space:
mode:
Diffstat (limited to 'tst/test_listen.py')
-rw-r--r--tst/test_listen.py8
1 files changed, 8 insertions, 0 deletions
diff --git a/tst/test_listen.py b/tst/test_listen.py
index 4d49ae2..ea58cc9 100644
--- a/tst/test_listen.py
+++ b/tst/test_listen.py
@@ -241,3 +241,11 @@ async def test_unallowed_method(base_url, request):
                     await writer.drain()
                     response = await reader.readuntil(b'\r\n')
                     assert response == b'HTTP/1.1 405 Method Not Allowed\r\n'
+
+
+@given(urls())
+def test_with_trailing_slash(base_url):
+    if base_url.endswith('/'):
+        assert with_trailing_slash(base_url) == base_url
+    else:
+        assert with_trailing_slash(base_url) == f'{base_url}/'