aboutsummaryrefslogtreecommitdiff
path: root/src/net/http
diff options
context:
space:
mode:
Diffstat (limited to 'src/net/http')
-rw-r--r--src/net/http/client_test.go2
-rw-r--r--src/net/http/cookiejar/jar.go2
-rw-r--r--src/net/http/transport_test.go10
3 files changed, 7 insertions, 7 deletions
diff --git a/src/net/http/client_test.go b/src/net/http/client_test.go
index b8c914bfd0..0fe555af38 100644
--- a/src/net/http/client_test.go
+++ b/src/net/http/client_test.go
@@ -1207,7 +1207,7 @@ func testClientTimeout(t *testing.T, mode testMode) {
}))
// Try to trigger a timeout after reading part of the response body.
- // The initial timeout is emprically usually long enough on a decently fast
+ // The initial timeout is empirically usually long enough on a decently fast
// machine, but if we undershoot we'll retry with exponentially longer
// timeouts until the test either passes or times out completely.
// This keeps the test reasonably fast in the typical case but allows it to
diff --git a/src/net/http/cookiejar/jar.go b/src/net/http/cookiejar/jar.go
index e1ba5971e0..d573147650 100644
--- a/src/net/http/cookiejar/jar.go
+++ b/src/net/http/cookiejar/jar.go
@@ -472,7 +472,7 @@ func (j *Jar) domainAndType(host, domain string) (string, bool, error) {
// would be sent to every subdomain of bbc.co.uk.
// It just doesn't make sense on IP addresses.
// The other processing and validation steps in RFC 6265 just
- // collaps to:
+ // collapse to:
if host != domain {
return "", false, errIllegalDomain
}
diff --git a/src/net/http/transport_test.go b/src/net/http/transport_test.go
index fdbc5daa8d..172aba679b 100644
--- a/src/net/http/transport_test.go
+++ b/src/net/http/transport_test.go
@@ -251,7 +251,7 @@ func testTransportConnectionCloseOnResponse(t *testing.T, mode testMode) {
// an underlying TCP connection after making an http.Request with Request.Close set.
//
// It tests the behavior by making an HTTP request to a server which
-// describes the source source connection it got (remote port number +
+// describes the source connection it got (remote port number +
// address of its net.Conn).
func TestTransportConnectionCloseOnRequest(t *testing.T) {
run(t, testTransportConnectionCloseOnRequest, []testMode{http1Mode})
@@ -2368,7 +2368,7 @@ func testTransportResponseHeaderTimeout(t *testing.T, mode testMode) {
if !tt.wantTimeout {
if !retry {
// The timeout may be set too short. Retry with a longer one.
- t.Logf("unexpected timout for path %q after %v; retrying with longer timeout", tt.path, timeout)
+ t.Logf("unexpected timeout for path %q after %v; retrying with longer timeout", tt.path, timeout)
timeout *= 2
retry = true
}
@@ -5648,7 +5648,7 @@ func testClientTimeoutKillsConn_BeforeHeaders(t *testing.T, mode testMode) {
_, err := cst.c.Get(cst.ts.URL)
if err == nil {
close(cancelHandler)
- t.Fatal("unexpected Get succeess")
+ t.Fatal("unexpected Get success")
}
tooSlow := time.NewTimer(timeout * 10)
@@ -5656,8 +5656,8 @@ func testClientTimeoutKillsConn_BeforeHeaders(t *testing.T, mode testMode) {
case <-tooSlow.C:
// If we didn't get into the Handler, that probably means the builder was
// just slow and the Get failed in that time but never made it to the
- // server. That's fine; we'll try again with a longer timout.
- t.Logf("no handler seen in %v; retrying with longer timout", timeout)
+ // server. That's fine; we'll try again with a longer timeout.
+ t.Logf("no handler seen in %v; retrying with longer timeout", timeout)
close(cancelHandler)
cst.close()
timeout *= 2