From ad3742f4acbf20c681c9f6f6775ea7ece85e5881 Mon Sep 17 00:00:00 2001 From: Brad Fitzpatrick Date: Thu, 2 Nov 2017 19:17:13 +0000 Subject: [PATCH] net/http: remove some log spam in test, add missing error detail Updates #22540 Change-Id: I26e79c25652976fac6f2e5a7afb4fd1240996d74 Reviewed-on: https://go-review.googlesource.com/75531 Reviewed-by: Tom Bergan Run-TryBot: Tom Bergan TryBot-Result: Gobot Gobot --- src/net/http/transport_test.go | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/net/http/transport_test.go b/src/net/http/transport_test.go index 31cf9170665..997a9153d0b 100644 --- a/src/net/http/transport_test.go +++ b/src/net/http/transport_test.go @@ -1113,15 +1113,14 @@ func TestTransportProxy(t *testing.T) { Header: make(Header), } - log.Printf("Dialing %s", r.URL.Host) targetConn, err := net.Dial("tcp", r.URL.Host) if err != nil { - t.Errorf("net.Dial failed") + t.Errorf("net.Dial(%q) failed: %v", r.URL.Host, err) return } if err := res.Write(clientConn); err != nil { - t.Errorf("Writing 200 OK failed") + t.Errorf("Writing 200 OK failed: %v", err) return }