Commit cc35563
Fix FutureMonadTest flakiness on Scala 2.12 under CI load
The test used `intercept[RuntimeException]` around `.futureValue`, but
`TestFailedException` (thrown on timeout) is a `RuntimeException` subclass.
On a loaded CI machine, the 150ms default patience expired before the
finalizer future completed, causing the intercept to silently catch the
timeout instead of the expected "boom!" exception. Result: `ran.get` was
`false` even though `intercept` appeared to succeed.
Fix: mix in `ScalaFutures` to allow a 10s patience override, and use
`.failed.futureValue` so a timeout throws `TestFailedException` uncaught
rather than being mistaken for the expected exception.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>1 parent 484bbe5 commit cc35563
1 file changed
Lines changed: 6 additions & 6 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
3 | | - | |
| 3 | + | |
4 | 4 | | |
5 | 5 | | |
| 6 | + | |
6 | 7 | | |
7 | 8 | | |
8 | 9 | | |
9 | 10 | | |
10 | 11 | | |
11 | | - | |
| 12 | + | |
| 13 | + | |
12 | 14 | | |
13 | 15 | | |
14 | 16 | | |
15 | 17 | | |
16 | 18 | | |
17 | | - | |
18 | | - | |
19 | | - | |
20 | | - | |
| 19 | + | |
| 20 | + | |
21 | 21 | | |
22 | 22 | | |
23 | 23 | | |
0 commit comments