Increase a bunch of timeouts to reduce flakes

This commit is contained in:
Brendan Burns
2015-09-16 11:52:07 -07:00
parent efedcb6ca1
commit 77fd388485
15 changed files with 50 additions and 36 deletions

View File

@@ -59,8 +59,8 @@ func TestCloseWatchChannelOnError(t *testing.T) {
if ok {
t.Errorf("Watch channel left open after cancellation")
}
case <-time.After(100 * time.Millisecond):
t.Errorf("the cancellation is at least 99 milliseconds late")
case <-time.After(util.ForeverTestTimeout):
t.Errorf("the cancellation is at least %s late", util.ForeverTestTimeout.String())
break
}
}
@@ -88,8 +88,8 @@ func TestRunUntil(t *testing.T) {
if ok {
t.Errorf("Watch channel left open after stopping the watch")
}
case <-time.After(100 * time.Millisecond):
t.Errorf("the cancellation is at least 99 milliseconds late")
case <-time.After(util.ForeverTestTimeout):
t.Errorf("the cancellation is at least %s late", util.ForeverTestTimeout.String())
break
}
}
@@ -98,7 +98,7 @@ func TestReflector_resyncChan(t *testing.T) {
s := NewStore(MetaNamespaceKeyFunc)
g := NewReflector(&testLW{}, &api.Pod{}, s, time.Millisecond)
a, _ := g.resyncChan()
b := time.After(100 * time.Millisecond)
b := time.After(util.ForeverTestTimeout)
select {
case <-a:
t.Logf("got timeout as expected")