]> Cypherpunks repositories - gostls13.git/commit
net/http: correctly test for leading header spaces in TestReadRequest_Bad
authorDamien Neil <dneil@google.com>
Fri, 2 Sep 2022 21:48:28 +0000 (14:48 -0700)
committerDamien Neil <dneil@google.com>
Mon, 19 Sep 2022 17:14:09 +0000 (17:14 +0000)
commite7312b1005e77633a4fbd3a5cbb371aef45b0867
tree315db16f8b3f6f6de2897f2be16c70d5a115ca22
parentd8e6ed32622b692c79a4db42e878921e1d3f16a8
net/http: correctly test for leading header spaces in TestReadRequest_Bad

TestReadRequest_Bad's tests for leading whitespace in the first header
were also exercising the test verifying that a HEAD request has no
Content-Length. Also, the test intended to test a leading tab was
actually testing for a leading \t (literal backslash, literal t).

Change-Id: I05b46d05851b49bf75f1d1257c421b953b66ea9c
Reviewed-on: https://go-review.googlesource.com/c/go/+/428134
Reviewed-by: Cherry Mui <cherryyz@google.com>
Run-TryBot: Damien Neil <dneil@google.com>
TryBot-Result: Gopher Robot <gobot@golang.org>
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
src/net/http/readrequest_test.go