Don't modify URL passed into test code
parent
bb326a6815
commit
a54bd4e20b
|
@ -32,9 +32,10 @@ const (
|
||||||
|
|
||||||
// urlFor returns a URL with the path and query params correctly appended and set.
|
// urlFor returns a URL with the path and query params correctly appended and set.
|
||||||
func urlFor(u *url.URL, path string, params url.Values) *url.URL {
|
func urlFor(u *url.URL, path string, params url.Values) *url.URL {
|
||||||
u.Path = path
|
v, _ := url.Parse(u.String())
|
||||||
u.RawQuery = params.Encode()
|
v.Path = path
|
||||||
return u
|
v.RawQuery = params.Encode()
|
||||||
|
return v
|
||||||
}
|
}
|
||||||
|
|
||||||
// node represents a node under test, which is both a broker and data node.
|
// node represents a node under test, which is both a broker and data node.
|
||||||
|
|
Loading…
Reference in New Issue