fix flaky test panic (#12446)
This commit is contained in:
parent
a97d20cf63
commit
4b0f657b31
|
@ -156,6 +156,9 @@ func TestLeader_FailedMember(t *testing.T) {
|
||||||
if err != nil {
|
if err != nil {
|
||||||
r.Fatalf("err: %v", err)
|
r.Fatalf("err: %v", err)
|
||||||
}
|
}
|
||||||
|
if len(checks) != 1 {
|
||||||
|
r.Fatalf("client missing check")
|
||||||
|
}
|
||||||
if got, want := checks[0].Status, api.HealthCritical; got != want {
|
if got, want := checks[0].Status, api.HealthCritical; got != want {
|
||||||
r.Fatalf("got status %q want %q", got, want)
|
r.Fatalf("got status %q want %q", got, want)
|
||||||
}
|
}
|
||||||
|
@ -703,6 +706,9 @@ func TestLeader_Reconcile_Races(t *testing.T) {
|
||||||
if err != nil {
|
if err != nil {
|
||||||
r.Fatalf("err: %v", err)
|
r.Fatalf("err: %v", err)
|
||||||
}
|
}
|
||||||
|
if len(checks) != 1 {
|
||||||
|
r.Fatalf("client missing check")
|
||||||
|
}
|
||||||
if got, want := checks[0].Status, api.HealthCritical; got != want {
|
if got, want := checks[0].Status, api.HealthCritical; got != want {
|
||||||
r.Fatalf("got state %q want %q", got, want)
|
r.Fatalf("got state %q want %q", got, want)
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue