1
0
mirror of https://github.com/spaam/svtplay-dl.git synced 2024-11-23 19:55:38 +01:00

test: improve get_full_url

This commit is contained in:
Johan Andersson 2019-09-07 12:27:36 +02:00
parent e9fca7a771
commit addf05baa9

View File

@ -21,5 +21,7 @@ class HttpTest(unittest.TestCase):
{"srcurl": "http://example.com/bar", "segment": "foo.ts", "expected": "http://example.com/foo.ts"},
# with query parameters
{"srcurl": "http://example.com/bar?baz=qux", "segment": "foo.ts", "expected": "http://example.com/foo.ts"},
# with segment with slash
{"srcurl": "http://example.com/bar", "segment": "/test", "expected": "http://example.com/test"},
]:
assert get_full_url(test["segment"], test["srcurl"]) == test["expected"]