Skip to content

Commit ad484d0

Browse files
mergify[bot]faec
andauthored
Increase timeout on flaky SQS test (#43672) (#43692)
`TestCancelWithGrace` in `sqs_test.go` has a timer correctness margin of only 5ms. This is much too low for a reliable test, timers are not guaranteed to have that granularity (especially on CI nodes where there are often execution delays). I saw it "failing" a couple times because it expected a duration of 1.0 seconds and instead got 1.006. This PR increases the acceptable margin to 50ms instead of 5. Closes #43668. (cherry picked from commit 7a95d64) # Conflicts: # x-pack/filebeat/input/awss3/sqs_test.go Co-authored-by: Fae Charlton <[email protected]>
1 parent ff8c579 commit ad484d0

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

x-pack/filebeat/input/awss3/sqs_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -292,7 +292,7 @@ func TestCancelWithGrace(t *testing.T) {
292292
const (
293293
wait = time.Second
294294
tooLong = time.Second
295-
tol = 10 * time.Millisecond
295+
tol = 100 * time.Millisecond
296296
)
297297
parentCtx, parentCancel := context.WithCancel(context.Background())
298298
childCtx, childCancel := cancelWithGrace(parentCtx, wait)

0 commit comments

Comments
 (0)