Skip to content

Commit 945e062

Browse files
dbrattliclaude
andcommitted
chore(rust): widen sleep gap in flaky Async.Sleep test
The test relied on Async.Sleep(100) finishing before Async.Sleep(300), but the 200ms gap is not robust on loaded CI runners — the second task can be queued >200ms after the first, inverting the order. Widen the gap to 100ms vs 1000ms. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
1 parent 64c1b07 commit 945e062

1 file changed

Lines changed: 3 additions & 3 deletions

File tree

tests/Rust/tests/src/AsyncTests.fs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -228,8 +228,8 @@ let ``Async.Sleep works`` () =
228228
let mutable s = ""
229229
let a1 =
230230
async {
231-
do! Async.Sleep(300)
232-
s <- s + "300"
231+
do! Async.Sleep(1000)
232+
s <- s + "1000"
233233
}
234234
let a2 =
235235
async {
@@ -240,7 +240,7 @@ let ``Async.Sleep works`` () =
240240
let t2 = a2 |> Async.StartAsTask
241241
let r1 = t1.Result
242242
let r2 = t2.Result
243-
s |> equal "100300"
243+
s |> equal "1001000"
244244

245245
// type DisposableAction(f) =
246246
// interface IDisposable with

0 commit comments

Comments
 (0)