fix: apply the run credential to the npm ping probe
What does this MR do and why?
npm.meta.ping built its GET /-/ping request with a raw http.NewRequestWithContext and sent it through ne.HTTPClient(). That path never reaches client.Client.newRequest, which is where applyCredential runs, so the probe sent no credential at all. Against any registry that authenticates /-/ping, the row could therefore only ever report 401, whatever the route actually does — pointing triage at the credential instead of at the route.
The raw request also omitted the standard User-Agent: registry-conformance/... header that S06 §Request shape requires on every request.
This builds the ping request through the npm client so it carries the run credential and the standard request shape, while still reading the response body directly (the body assertion cannot use the body-discarding Client.Ping).
Closes #87 (closed).
How
pkg/client/npm/client.go: added an exportedClient.NewRequestthat wraps the existing unexportednewRequest. It applies the credential and the S06 request shape (User-Agent, Content-Type rules); it does not send the request, so a caller that must read the response body itself can still obtain a correctly-shaped, credentialed request.pkg/conformance/npm/meta.go:testMetaPingnow builds its request viane.Client().NewRequest(...)instead of a rawhttp.NewRequestWithContext. The request is still sent throughne.HTTPClient()so the probe keeps the run's request timeout and cross-host-redirect SSRF policy, and the body is still read directly for the{}assertion.
Test coverage
pkg/conformance/npm/meta_test.go: the test registry now records the ping request'sAuthorizationandUser-Agentheaders, and a new test,TestMetaPing_appliesCredential, asserts a bearer run credential reaches the registry asAuthorization: Bearer <token>and that the standard User-Agent is present. The test fails before the change (empty Authorization) and passes after it.go build ./...,go vet, andgofmtare clean; the fullpkg/conformance/npmpackage passes.