Skip to content

Commit

Permalink
runtime: Make plugin readiness timeout tests a bit more forgiving
Browse files Browse the repository at this point in the history
We were starting to see test flakes because the timeouts were not very
forgiving. Bumping them so that the difference is orders of magnitude
to account for environments like GHA.

Signed-off-by: Torin Sandall <torinsandall@gmail.com>
  • Loading branch information
tsandall committed Aug 10, 2020
1 parent b5b3280 commit 1410f91
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions runtime/plugins_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -171,7 +171,8 @@ func TestWaitPluginsReady(t *testing.T) {
})

go func() {
time.Sleep(2 * time.Millisecond)
time.Sleep(100 * time.Millisecond)

rt.Manager.UpdatePluginStatus("test", &plugins.Status{
State: plugins.StateOK,
})
Expand All @@ -188,7 +189,7 @@ func TestWaitPluginsReady(t *testing.T) {
t.Fatal("Expected timeout error")
}

if err := rt.waitPluginsReady(1*time.Millisecond, 3*time.Millisecond); err != nil {
if err := rt.waitPluginsReady(1*time.Millisecond, time.Second); err != nil {
t.Fatal(err)
}
})
Expand Down

0 comments on commit 1410f91

Please sign in to comment.