def METHOD_NAME(
    http: type[httpretty.httpretty], uploader: Uploader
) -> None:
    http.register_uri(http.POST, "https://foo.com", status=301, body="Redirect")
    with pytest.raises(UploadError) as e:
        uploader.upload("https://foo.com")
    assert (
        str(e.value)
        == "Redirects are not supported. Is the URL missing a trailing slash?"
    )