net/http/internal/http2: remove TestClientConnPing

Ping is no longer a public API.

For #67810

Change-Id: I7df19d443634ada23cf4137b96cb25676a6a6964
Reviewed-on: https://go-review.googlesource.com/c/go/+/751311
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>
Auto-Submit: Damien Neil <dneil@google.com>
Reviewed-by: Nicholas Husin <nsh@golang.org>
Reviewed-by: Nicholas Husin <husin@google.com>
This commit is contained in:
Damien Neil
2026-03-03 15:46:00 -08:00
committed by Gopher Robot
parent 62dfe99dab
commit 74649c1cc5

View File

@@ -2650,22 +2650,6 @@ func testRoundTripDoesntConsumeRequestBodyEarly(t testing.TB) {
}
}
func TestClientConnPing(t *testing.T) {
ts := newTestServer(t, func(w http.ResponseWriter, r *http.Request) {})
tr := &Transport{
TLSClientConfig: tlsConfigInsecure,
}
defer tr.CloseIdleConnections()
ctx := context.Background()
cc, err := tr.DialClientConn(ctx, ts.Listener.Addr().String(), false)
if err != nil {
t.Fatal(err)
}
if err = cc.Ping(context.Background()); err != nil {
t.Fatal(err)
}
}
// Issue 16974: if the server sent a DATA frame after the user
// canceled the Transport's Request, the Transport previously wrote to a
// closed pipe, got an error, and ended up closing the whole TCP