mirror of
https://github.com/VictoriaMetrics/VictoriaMetrics.git
synced 2024-11-21 14:44:00 +00:00
lib/promauth: follow-up b577413d3b
Convert test result expectations to canonical form.
Starting from b577413d3b
specified header keys are forced
into canonical form https://pkg.go.dev/net/http#CanonicalHeaderKey
Signed-off-by: hagen1778 <roman@victoriametrics.com>
This commit is contained in:
parent
4553521f9a
commit
e6dd52b04c
2 changed files with 4 additions and 3 deletions
|
@ -31,6 +31,7 @@ See also [LTS releases](https://docs.victoriametrics.com/lts-releases/).
|
|||
## tip
|
||||
|
||||
**Update note 1: the `-datasource.lookback` command-line flag at `vmalert` is no-op starting from this release. This flag will be removed in the future, so please switch to [`eval_delay` option](https://docs.victoriametrics.com/vmalert/#groups). See [this issue](https://github.com/VictoriaMetrics/VictoriaMetrics/issues/5155) for more details.**
|
||||
**Update note 2: transform custom HTTP header keys specified via [`headers` option](https://docs.victoriametrics.com/sd_configs/#http-api-client-options) for scrape targets to [canonical form](https://pkg.go.dev/net/http#CanonicalHeaderKey).**
|
||||
|
||||
* SECURITY: upgrade Go builder from Go1.21.7 to Go1.22.1. See [the list of issues addressed in Go1.22.1](https://github.com/golang/go/issues?q=milestone%3AGo1.22.1+label%3ACherryPickApproved).
|
||||
|
||||
|
|
|
@ -538,8 +538,8 @@ func TestParseHeadersSuccess(t *testing.T) {
|
|||
}
|
||||
}
|
||||
f(nil)
|
||||
f([]string{"foo: bar"})
|
||||
f([]string{"Foo: bar", "A-b-c: d-e-f"})
|
||||
f([]string{"Foo: bar"})
|
||||
f([]string{"Foo: bar", "A-B-C: d-e-f"})
|
||||
}
|
||||
|
||||
func TestParseHeadersFailure(t *testing.T) {
|
||||
|
@ -590,6 +590,6 @@ func TestConfigHeaders(t *testing.T) {
|
|||
}
|
||||
}
|
||||
f(nil, "")
|
||||
f([]string{"foo: bar"}, "foo: bar\r\n")
|
||||
f([]string{"foo: bar"}, "Foo: bar\r\n")
|
||||
f([]string{"Foo-Bar: Baz s:sdf", "A:b", "X-Forwarded-For: A-B:c"}, "Foo-Bar: Baz s:sdf\r\nA: b\r\nX-Forwarded-For: A-B:c\r\n")
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue