MCPcopy Create free account
hub / github.com/atomicdotdev/atomic / test_parse_session_end_with_reason

Function test_parse_session_end_with_reason

atomic-agent/src/hooks/copilot.rs:619–625  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

617
618 #[test]
619 fn test_parse_session_end_with_reason() {
620 let hook = make_hook();
621 let input = br#"{"session_id": "s1", "reason": "timeout"}"#;
622 let event = hook.parse_event(HookType::SessionEnd, input).unwrap();
623 let raw = event.raw_json.unwrap();
624 assert_eq!(raw["reason"], "timeout");
625 }
626
627 // ── parse_event tests: user-prompt (TurnStart) ──────────────────
628

Callers

nothing calls this directly

Calls 3

make_hookFunction · 0.70
unwrapMethod · 0.45
parse_eventMethod · 0.45

Tested by

no test coverage detected