testFormValuesList checks that the request form values match the expected values. It allows for multiple values per key.
(t *testing.T, r *http.Request, want url.Values)
| 183 | // testFormValuesList checks that the request form values match the expected values. |
| 184 | // It allows for multiple values per key. |
| 185 | func testFormValuesList(t *testing.T, r *http.Request, want url.Values) { |
| 186 | t.Helper() |
| 187 | |
| 188 | assertNilError(t, r.ParseForm()) |
| 189 | if got := r.Form; !cmp.Equal(got, want) { |
| 190 | t.Errorf("Request query parameters: %v, want %v", got, want) |
| 191 | } |
| 192 | } |
| 193 | |
| 194 | func testHeader(t *testing.T, r *http.Request, header, want string) { |
| 195 | t.Helper() |
no test coverage detected
searching dependent graphs…