Context
run_scheduler_loop() (modified in #1603) exits with GraphStatus::Failed when the channel is closed (Ok(None) or Err(_) from channel.recv()). This transition is not directly tested.
Acceptance criteria
A #[tokio::test] that:
- Builds an agent with a MockChannel that immediately returns
Ok(None) from recv()
- Runs
run_scheduler_loop() with an active graph
- Asserts the returned status is
GraphStatus::Failed
Note: MockChannel::new(vec![]) already returns Ok(None) when the message list is empty, so this test can be simple.
Labels
enhancement, testing