test(df): use a reserved port for the unreachable Go proxy

Why

TestRunUpstreamDown/, flaked on main: https://gitlab.com/gitlab-org/cli/-/jobs/18321466936

closedAddr listened on 127.0.0.1:0, closed the listener, and returned the address. Before Go dialed it, a parallel test server was bound to the freed port and answered 502 Bad Gateway, so the connection refused assertion failed.

What

Replace closedAddr with a constant 127.0.0.1:1. Port 1 is below the ephemeral range, so no test server can be handed it and every dial is refused. TestRunUpstreamFailureHidesURLCredentials used the same helper and gets the same fix.

The assertions are unchanged and still pass.

🤖 Generated with Claude Code

Merge request reports

Loading
Loading