Commit e283499
Queue::fake the two cancel/terminate-while-waiting-on-activity tests
Same bucket A pattern as d042ea9: tests that wait for the workflow
to park on an activity were racing the real testbench queue workers.
Activity-wait variants weren't covered by d042ea9 (which only handled
timer-wait variants).
Conversion uses runReadyTaskForRun(Workflow) before the waitFor instead
of drainReadyTasks because draining further would also run the dispatched
activity task and complete the activity before the test could cancel.
After the cancel, drainReadyTasks finishes the cancellation workflow task
chain.
Clears 2 CI-only MySQL failures under #399:
* testWorkflowCanBeCancelledWithReasonWhileWaitingOnActivity
* testWorkflowCanBeTerminatedWithReasonWhileWaitingOnActivity
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>1 parent 543c0ec commit e283499
1 file changed
Lines changed: 12 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
7731 | 7731 | | |
7732 | 7732 | | |
7733 | 7733 | | |
| 7734 | + | |
| 7735 | + | |
7734 | 7736 | | |
7735 | 7737 | | |
7736 | 7738 | | |
7737 | 7739 | | |
7738 | 7740 | | |
7739 | 7741 | | |
7740 | 7742 | | |
| 7743 | + | |
| 7744 | + | |
7741 | 7745 | | |
7742 | 7746 | | |
7743 | 7747 | | |
7744 | 7748 | | |
7745 | 7749 | | |
| 7750 | + | |
| 7751 | + | |
7746 | 7752 | | |
7747 | 7753 | | |
7748 | 7754 | | |
| |||
7815 | 7821 | | |
7816 | 7822 | | |
7817 | 7823 | | |
| 7824 | + | |
| 7825 | + | |
7818 | 7826 | | |
7819 | 7827 | | |
7820 | 7828 | | |
7821 | 7829 | | |
7822 | 7830 | | |
7823 | 7831 | | |
7824 | 7832 | | |
| 7833 | + | |
| 7834 | + | |
7825 | 7835 | | |
7826 | 7836 | | |
7827 | 7837 | | |
7828 | 7838 | | |
7829 | 7839 | | |
| 7840 | + | |
| 7841 | + | |
7830 | 7842 | | |
7831 | 7843 | | |
7832 | 7844 | | |
| |||
0 commit comments