From b1a176845636fc9dbc70c3020adafae69279efe2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Wojciech=20Tyczy=C5=84ski?= Date: Tue, 19 Mar 2024 20:23:56 +0100 Subject: [PATCH] Relax WatchSemanticsTest to make it faster Kubernetes-commit: a26ee123952eeb86467e61ff2eb744c9e736a045 --- pkg/storage/testing/utils.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/pkg/storage/testing/utils.go b/pkg/storage/testing/utils.go index 5564f3c86..e30f08618 100644 --- a/pkg/storage/testing/utils.go +++ b/pkg/storage/testing/utils.go @@ -197,7 +197,8 @@ func testCheckNoMoreResults(t *testing.T, w watch.Interface) { select { case e := <-w.ResultChan(): t.Errorf("Unexpected: %#v event received, expected no events", e) - case <-time.After(time.Second): + // We consciously make the timeout short here to speed up tests. + case <-time.After(100 * time.Millisecond): return } }