()
| 277 | |
| 278 | #[tokio::test] |
| 279 | async fn isolates_failed_and_panicked_steps() { |
| 280 | let exec: Arc<dyn AgentExecutor> = Arc::new(MockExecutor::new(8)); |
| 281 | let specs = vec![ |
| 282 | spec("ok", "explore"), |
| 283 | spec("bad", "fail"), |
| 284 | spec("crash", "boom"), |
| 285 | spec("ok2", "review"), |
| 286 | ]; |
| 287 | let out = execute_steps_parallel(exec, specs, None).await; |
| 288 | assert_eq!(out.len(), 4, "every step yields a result"); |
| 289 | assert!(out[0].success); |
| 290 | assert!( |
| 291 | !out[1].success, |
| 292 | "explicit failure surfaces as success=false" |
| 293 | ); |
| 294 | assert!( |
| 295 | !out[2].success && out[2].agent == "boom", |
| 296 | "a panicked branch becomes a labelled failed outcome, not a drop" |
| 297 | ); |
| 298 | assert!(out[3].success, "later steps unaffected by an earlier panic"); |
| 299 | } |
| 300 | |
| 301 | #[tokio::test] |
| 302 | async fn default_concurrency_hint_is_the_framework_default() { |
nothing calls this directly
no test coverage detected