aboutsummaryrefslogtreecommitdiff
path: root/header_test.go
diff options
context:
space:
mode:
authorGravatar Erik Dubbelboer <erik@dubbelboer.com> 2022-07-29 19:03:15 +0200
committerGravatar GitHub <noreply@github.com> 2022-07-29 19:03:15 +0200
commita5f448fc970972ab47113971d898a22fb28fef52 (patch)
tree826fe1e91cdca5002f7db0bef4b8dfdcf55efddc /header_test.go
parentPrevent overflow and panic on large HTTP responses (#1351) (diff)
downloadfasthttp-a5f448fc970972ab47113971d898a22fb28fef52.tar.gz
fasthttp-a5f448fc970972ab47113971d898a22fb28fef52.tar.bz2
fasthttp-a5f448fc970972ab47113971d898a22fb28fef52.zip
Improve Client timeout (#1346)
Don't run requests in a separate Goroutine anymore. Instead use proper conn deadlines to enforce timeouts. - Also contains some linting fixes.
Diffstat (limited to 'header_test.go')
-rw-r--r--header_test.go8
1 files changed, 4 insertions, 4 deletions
diff --git a/header_test.go b/header_test.go
index ac8b5eb..3ea7706 100644
--- a/header_test.go
+++ b/header_test.go
@@ -1942,7 +1942,7 @@ func TestResponseHeaderCookieIssue4(t *testing.T) {
t.Fatalf("Unexpected Set-Cookie header %q. Expected %q", h.Peek(HeaderSetCookie), "foo=bar")
}
cookieSeen := false
- h.VisitAll(func(key, value []byte) {
+ h.VisitAll(func(key, _ []byte) {
switch string(key) {
case HeaderSetCookie:
cookieSeen = true
@@ -1963,7 +1963,7 @@ func TestResponseHeaderCookieIssue4(t *testing.T) {
t.Fatalf("Unexpected Set-Cookie header %q. Expected %q", h.Peek(HeaderSetCookie), "foo=bar")
}
cookieSeen = false
- h.VisitAll(func(key, value []byte) {
+ h.VisitAll(func(key, _ []byte) {
switch string(key) {
case HeaderSetCookie:
cookieSeen = true
@@ -1987,7 +1987,7 @@ func TestRequestHeaderCookieIssue313(t *testing.T) {
t.Fatalf("Unexpected Cookie header %q. Expected %q", h.Peek(HeaderCookie), "foo=bar")
}
cookieSeen := false
- h.VisitAll(func(key, value []byte) {
+ h.VisitAll(func(key, _ []byte) {
switch string(key) {
case HeaderCookie:
cookieSeen = true
@@ -2005,7 +2005,7 @@ func TestRequestHeaderCookieIssue313(t *testing.T) {
t.Fatalf("Unexpected Cookie header %q. Expected %q", h.Peek(HeaderCookie), "foo=bar")
}
cookieSeen = false
- h.VisitAll(func(key, value []byte) {
+ h.VisitAll(func(key, _ []byte) {
switch string(key) {
case HeaderCookie:
cookieSeen = true