mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-07-31 15:25:57 +00:00
Merge pull request #99442 from zgfh/fix-stress
[UT] AtMostEvery may result in less than expected times if overloaded
This commit is contained in:
commit
8370316d09
@ -45,7 +45,7 @@ func TestAtMostEvery(t *testing.T) {
|
||||
}
|
||||
}
|
||||
|
||||
if expected := int(duration/delay) + 1; count != expected {
|
||||
t.Fatalf("Function called %d times, should have been called exactly %d times", count, expected)
|
||||
if expected := int(duration/delay) + 1; count > expected {
|
||||
t.Fatalf("Function called %d times, should have been called less than or equal to %d times", count, expected)
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user