mirror of
https://github.com/caddyserver/caddy.git
synced 2025-01-13 22:36:27 +03:00
Clean up metrics test code
No need to use != for booleans
This commit is contained in:
parent
a479943acd
commit
a944de4ab7
1 changed files with 2 additions and 2 deletions
|
@ -21,7 +21,7 @@ func TestMetricsUnmarshalCaddyfile(t *testing.T) {
|
||||||
t.Errorf("unexpected error: %v", err)
|
t.Errorf("unexpected error: %v", err)
|
||||||
}
|
}
|
||||||
|
|
||||||
if m.DisableOpenMetrics != false {
|
if m.DisableOpenMetrics {
|
||||||
t.Errorf("DisableOpenMetrics should've been false: %v", m.DisableOpenMetrics)
|
t.Errorf("DisableOpenMetrics should've been false: %v", m.DisableOpenMetrics)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -32,7 +32,7 @@ func TestMetricsUnmarshalCaddyfile(t *testing.T) {
|
||||||
t.Errorf("unexpected error: %v", err)
|
t.Errorf("unexpected error: %v", err)
|
||||||
}
|
}
|
||||||
|
|
||||||
if m.DisableOpenMetrics != true {
|
if !m.DisableOpenMetrics {
|
||||||
t.Errorf("DisableOpenMetrics should've been true: %v", m.DisableOpenMetrics)
|
t.Errorf("DisableOpenMetrics should've been true: %v", m.DisableOpenMetrics)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue