()
| 608 | |
| 609 | #[test] |
| 610 | fn test_parse_session_end() { |
| 611 | let hook = make_hook(); |
| 612 | let input = br#"{"session_id": "cp-abc123", "reason": "user_exit"}"#; |
| 613 | let event = hook.parse_event(HookType::SessionEnd, input).unwrap(); |
| 614 | assert_eq!(event.session_id, "cp-abc123"); |
| 615 | assert_eq!(event.event_type, HookType::SessionEnd); |
| 616 | } |
| 617 | |
| 618 | #[test] |
| 619 | fn test_parse_session_end_with_reason() { |
nothing calls this directly
no test coverage detected