def test_get_absolute_url(): site = sites.get_current() assert get_absolute_url("http://domain/path") == "http://domain/path" assert get_absolute_url("/path") == build_url("/path", domain=site.domain, scheme=site.scheme)