1
0
mirror of https://github.com/home-assistant/supervisor.git synced 2025-12-21 02:49:41 +00:00
Files
supervisor/tests/misc/test_sanitise_url.py
Stefan Agner f6faa18409 Bump pre-commit ruff to 0.5.7 and reformat (#5242)
It seems that the codebase is not formatted with the latest ruff
version. This PR reformats the codebase with ruff 0.5.7.
2024-08-13 20:53:56 +02:00

11 lines
362 B
Python

"""Test supervisor.utils.sanitize_url."""
from supervisor.misc.filter import sanitize_url
def test_sanitize_url():
"""Test supervisor.utils.sanitize_url."""
assert sanitize_url("test") == "test"
assert sanitize_url("http://my.duckdns.org") == "http://example.com"
assert sanitize_url("http://my.duckdns.org/test") == "http://example.com/test"