Skip to content

Commit 66be61f

Browse files
committed
kvprober: remove unnecessary checks to avoid flakes
This commit removes two unnecessary checks, to avoid flakes. The removed checks can cause flakes, since they require all probes (of a certain type) to fail, even tho the test server is not configured to fail probes until after server startup. That is, there is a race condition. The checks are also unnecessary. What we really care about is the checks that follow the deleted ones: That the ten probes run within test all fail, since those happen after the test server is configured to fail probes. Release note: None. Epic: None.
1 parent 46255c8 commit 66be61f

File tree

1 file changed

+0
-4
lines changed

1 file changed

+0
-4
lines changed

pkg/kv/kvprober/kvprober_integration_test.go

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -171,8 +171,6 @@ func TestProberDoesReadsAndWrites(t *testing.T) {
171171
p.WriteProbe(ctx, s.DB())
172172
}
173173

174-
// Expect all read probes to fail but write probes & planning to succeed.
175-
require.Equal(t, p.Metrics().ReadProbeAttempts.Count(), p.Metrics().ReadProbeFailures.Count())
176174
// kvprober is running in background, so more than ten probes may be run.
177175
require.GreaterOrEqual(t, p.Metrics().ReadProbeFailures.Count(), int64(10))
178176

@@ -220,8 +218,6 @@ func TestProberDoesReadsAndWrites(t *testing.T) {
220218
p.WriteProbe(ctx, s.DB())
221219
}
222220

223-
// Expect all write probes to fail but read probes & planning to succeed.
224-
require.Equal(t, p.Metrics().WriteProbeAttempts.Count(), p.Metrics().WriteProbeFailures.Count())
225221
// kvprober is running in background, so more than ten probes may be run.
226222
require.GreaterOrEqual(t, p.Metrics().WriteProbeFailures.Count(), int64(10))
227223

0 commit comments

Comments
 (0)