()
| 1179 | |
| 1180 | #[test] |
| 1181 | fn test_full_lifecycle_ctrl_c_recovery() { |
| 1182 | let ctx = TransitionContext::default(); |
| 1183 | |
| 1184 | // Turn starts |
| 1185 | let r = transition(Phase::Idle, Event::TurnStart, ctx); |
| 1186 | assert_eq!(r.new_phase, Phase::Active); |
| 1187 | |
| 1188 | // Agent crashes, user sends another turn start |
| 1189 | let r = transition(Phase::Active, Event::TurnStart, ctx); |
| 1190 | assert_eq!(r.new_phase, Phase::Active); // Continues |
| 1191 | |
| 1192 | // New turn ends normally |
| 1193 | let r = transition(Phase::Active, Event::TurnEnd, ctx); |
| 1194 | assert_eq!(r.new_phase, Phase::Idle); |
| 1195 | assert!(r.requires_recording()); |
| 1196 | } |
| 1197 | |
| 1198 | // Exhaustive transition table test |
| 1199 |
nothing calls this directly
no test coverage detected