diff --git a/internal/downloader/downloader_test.go b/internal/downloader/downloader_test.go index e981dae..93b2f16 100644 --- a/internal/downloader/downloader_test.go +++ b/internal/downloader/downloader_test.go @@ -93,8 +93,7 @@ func TestDownload(t *testing.T) { ctx := downloader.NewContext("test_restricted_access.txt", server.URL) - err := ctx.Download(context.Background()) - if err == nil || err.Error() != "restricted access (credentials required)" { + if err := ctx.Download(context.Background()); err == nil || err.Error() != "restricted access (credentials required)" { t.Errorf("expected restricted access error, got %v", err) } })