()
| 697 | call_count = 0 |
| 698 | |
| 699 | def fake_time(): |
| 700 | nonlocal call_count |
| 701 | call_count += 1 |
| 702 | if call_count <= 2: |
| 703 | # First call: sets deadline = real_time + 1000 |
| 704 | # Second call: first remaining = 1000 - real_time ≈ 1000 (positive) |
| 705 | return real_time |
| 706 | else: |
| 707 | # All subsequent calls: pretend the clock has jumped far past the |
| 708 | # deadline so remaining ≤ 0 triggers. |
| 709 | return real_time + 100_000 |
| 710 | |
| 711 | results = [] |
| 712 | with mock.patch.object(real_loop, "time", side_effect=fake_time): |
nothing calls this directly
no outgoing calls
no test coverage detected