Commit ffbed5c2 authored by Russ Cox's avatar Russ Cox

net/http: fix tests for recent URL.RawPath addition

Change-Id: I35d20ed958c32d464b2c9d849403b6e3f99b6482
Reviewed-on: https://go-review.googlesource.com/11343Reviewed-by: default avatarRuss Cox <rsc@golang.org>
parent 9a3112bc
...@@ -45,9 +45,10 @@ var reqTests = []reqTest{ ...@@ -45,9 +45,10 @@ var reqTests = []reqTest{
&Request{ &Request{
Method: "GET", Method: "GET",
URL: &url.URL{ URL: &url.URL{
Scheme: "http", Scheme: "http",
Host: "www.techcrunch.com", Host: "www.techcrunch.com",
Path: "/", Path: "/",
RawPath: "/",
}, },
Proto: "HTTP/1.1", Proto: "HTTP/1.1",
ProtoMajor: 1, ProtoMajor: 1,
...@@ -82,7 +83,8 @@ var reqTests = []reqTest{ ...@@ -82,7 +83,8 @@ var reqTests = []reqTest{
&Request{ &Request{
Method: "GET", Method: "GET",
URL: &url.URL{ URL: &url.URL{
Path: "/", Path: "/",
RawPath: "/",
}, },
Proto: "HTTP/1.1", Proto: "HTTP/1.1",
ProtoMajor: 1, ProtoMajor: 1,
...@@ -108,7 +110,8 @@ var reqTests = []reqTest{ ...@@ -108,7 +110,8 @@ var reqTests = []reqTest{
&Request{ &Request{
Method: "GET", Method: "GET",
URL: &url.URL{ URL: &url.URL{
Path: "//user@host/is/actually/a/path/", Path: "//user@host/is/actually/a/path/",
RawPath: "//user@host/is/actually/a/path/",
}, },
Proto: "HTTP/1.1", Proto: "HTTP/1.1",
ProtoMajor: 1, ProtoMajor: 1,
...@@ -158,7 +161,8 @@ var reqTests = []reqTest{ ...@@ -158,7 +161,8 @@ var reqTests = []reqTest{
&Request{ &Request{
Method: "POST", Method: "POST",
URL: &url.URL{ URL: &url.URL{
Path: "/", Path: "/",
RawPath: "/",
}, },
TransferEncoding: []string{"chunked"}, TransferEncoding: []string{"chunked"},
Proto: "HTTP/1.1", Proto: "HTTP/1.1",
...@@ -232,7 +236,8 @@ var reqTests = []reqTest{ ...@@ -232,7 +236,8 @@ var reqTests = []reqTest{
&Request{ &Request{
Method: "CONNECT", Method: "CONNECT",
URL: &url.URL{ URL: &url.URL{
Path: "/_goRPC_", Path: "/_goRPC_",
RawPath: "/_goRPC_",
}, },
Proto: "HTTP/1.1", Proto: "HTTP/1.1",
ProtoMajor: 1, ProtoMajor: 1,
...@@ -303,7 +308,8 @@ var reqTests = []reqTest{ ...@@ -303,7 +308,8 @@ var reqTests = []reqTest{
&Request{ &Request{
Method: "GET", Method: "GET",
URL: &url.URL{ URL: &url.URL{
Path: "/", Path: "/",
RawPath: "/",
}, },
Header: Header{ Header: Header{
// This wasn't removed from Go 1.0 to // This wasn't removed from Go 1.0 to
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment