The HeartbeatService constructor was refactored to use an on_heartbeat callback instead of accepting provider/model parameters directly. This PR updates the tests to match the new API.
Changes
✅ Removed DummyProvider class (no longer needed)
✅ Updated test_start_is_idempotent to use new constructor
✅ Removed test_decide_returns_skip_when_no_tool_call (_decide method no longer exists)
✅ Updated test_trigger_now_executes_when_decision_is_run to use on_heartbeat callback
✅ Updated test_trigger_now_returns_none_when_no_callback to test new behavior
✅ Fixed bug where start() was not idempotent
Test Results
✅ All 3 HeartbeatService tests now pass
Type
Test fixes
Bug fix (idempotent start)
🤖 Generated with Claude Code
## Summary
The HeartbeatService constructor was refactored to use an `on_heartbeat` callback instead of accepting `provider`/`model` parameters directly. This PR updates the tests to match the new API.
## Changes
- ✅ Removed `DummyProvider` class (no longer needed)
- ✅ Updated `test_start_is_idempotent` to use new constructor
- ✅ Removed `test_decide_returns_skip_when_no_tool_call` (`_decide` method no longer exists)
- ✅ Updated `test_trigger_now_executes_when_decision_is_run` to use `on_heartbeat` callback
- ✅ Updated `test_trigger_now_returns_none_when_no_callback` to test new behavior
- ✅ Fixed bug where `start()` was not idempotent
## Test Results
✅ All 3 HeartbeatService tests now pass
## Type
- [x] Test fixes
- [x] Bug fix (idempotent start)
🤖 Generated with Claude Code
The HeartbeatService constructor was refactored to use an on_heartbeat
callback instead of accepting provider/model parameters directly. This
commit updates the tests to match the new API:
- Removed DummyProvider class (no longer needed)
- Updated test_start_is_idempotent to use new constructor
- Removed test_decide_returns_skip_when_no_tool_call (_decide method no longer exists)
- Updated test_trigger_now_executes_when_decision_is_run to use on_heartbeat callback
- Updated test_trigger_now_returns_none_when_no_callback to test new behavior
Also fixed a bug where start() was not idempotent - it now checks if a
task is already running before creating a new one.
All 3 HeartbeatService tests now pass.
Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
Summary
The HeartbeatService constructor was refactored to use an
on_heartbeatcallback instead of acceptingprovider/modelparameters directly. This PR updates the tests to match the new API.Changes
DummyProviderclass (no longer needed)test_start_is_idempotentto use new constructortest_decide_returns_skip_when_no_tool_call(_decidemethod no longer exists)test_trigger_now_executes_when_decision_is_runto useon_heartbeatcallbacktest_trigger_now_returns_none_when_no_callbackto test new behaviorstart()was not idempotentTest Results
✅ All 3 HeartbeatService tests now pass
Type
🤖 Generated with Claude Code