Commit 069ba7e
committed
test(timer): fix flaky StopTokenCancelsOne on IOCP
The test raced a 10ms delay timer against the 500ms shared timer t to
drive cancellation. Under a runtime stall both expire together and t
completes w1 with success before the delay-driven request_stop() runs,
so the cancellation assertion fails intermittently in CI.
Drop the delay timer; call request_stop() from a posted task instead.
run_async queues it FIFO, so both waiters register on t before the
cancel runs — deterministic, no wall-clock margin.1 parent 22d9d0e commit 069ba7e
1 file changed
Lines changed: 8 additions & 3 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
633 | 633 | | |
634 | 634 | | |
635 | 635 | | |
636 | | - | |
637 | 636 | | |
638 | 637 | | |
639 | 638 | | |
640 | 639 | | |
641 | 640 | | |
642 | 641 | | |
643 | | - | |
644 | 642 | | |
645 | 643 | | |
646 | 644 | | |
| |||
656 | 654 | | |
657 | 655 | | |
658 | 656 | | |
| 657 | + | |
| 658 | + | |
| 659 | + | |
| 660 | + | |
| 661 | + | |
| 662 | + | |
| 663 | + | |
659 | 664 | | |
660 | | - | |
661 | 665 | | |
| 666 | + | |
662 | 667 | | |
663 | 668 | | |
664 | 669 | | |
| |||
0 commit comments