Skip to content

Commit f0217c5

Browse files
committed
Refactor Expect module for improved exception handling in asynchronous operations
1 parent 74684a4 commit f0217c5

File tree

1 file changed

+7
-3
lines changed

1 file changed

+7
-3
lines changed

tests/IcedTasks.Tests/Expect.fs

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -156,9 +156,13 @@ type ManualTimeProviderExtensions =
156156
do! Task.Yield()
157157
this.Advance(time)
158158
//https://github.com/dotnet/runtime/issues/85326
159-
do! Task.yieldMany 100
160-
do! Task.Delay(15)
161-
do! Task.yieldMany 100
159+
// I'm not sure why we have to do this many yields, but sometimes the timer doesn't fire and the test run forever.
160+
// I've spent way too much time on this already.
161+
do!
162+
Task.yieldMany (
163+
Int32.MaxValue
164+
/ 100000
165+
)
162166
}
163167

164168

0 commit comments

Comments
 (0)