From bbb82574747f2323e876dcd3cede1b996daef9a2 Mon Sep 17 00:00:00 2001 From: "J. Nick Koston" Date: Sun, 20 Oct 2024 21:50:28 -1000 Subject: [PATCH] Add coverage for passing encoded `SplitResult` to create a `URL` (#1366) --- tests/test_url.py | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/tests/test_url.py b/tests/test_url.py index 549449d4..adfd4219 100644 --- a/tests/test_url.py +++ b/tests/test_url.py @@ -1967,6 +1967,11 @@ def test_split_result_non_decoded(): URL(SplitResult("http", "example.com", "path", "qs", "frag")) +def test_split_result_encoded(): + url = URL(SplitResult("http", "example.com", "path", "qs", "frag"), encoded=True) + assert str(url) == "http://example.com/path?qs#frag" + + def test_human_repr(): url = URL("http://бажан:пароль@хост.домен:8080/шлях/сюди?арг=вал#фраг") s = url.human_repr()