Skip to content

Commit d066f03

Browse files
committed
test(utils): Add test for sanitize_url
Fixes: GH-3515
1 parent 8d7bfab commit d066f03

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

tests/test_utils.py

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -366,6 +366,12 @@ def test_sanitize_url_and_split(url, expected_result):
366366
assert sanitized_url.fragment == expected_result.fragment
367367

368368

369+
def test_sanitize_url_remove_authority_is_false():
370+
url = "https://usr:[email protected]"
371+
sanitized_url = sanitize_url(url, remove_authority=False)
372+
assert sanitized_url == url
373+
374+
369375
@pytest.mark.parametrize(
370376
("url", "sanitize", "expected_url", "expected_query", "expected_fragment"),
371377
[

0 commit comments

Comments
 (0)