()
| 949 | |
| 950 | #[test] |
| 951 | fn test_parse_after_tool() { |
| 952 | let hook = make_hook(); |
| 953 | let input = br#"{"session_id": "sess-123", "tool_name": "read_file", "tool_response": {"content": "hello"}}"#; |
| 954 | let event = hook.parse_event(HookType::PostToolUse, input).unwrap(); |
| 955 | assert_eq!(event.session_id, "sess-123"); |
| 956 | assert_eq!(event.event_type, HookType::PostToolUse); |
| 957 | assert_eq!(event.tool_name.as_deref(), Some("read_file")); |
| 958 | } |
| 959 | |
| 960 | #[test] |
| 961 | fn test_parse_empty_input() { |
nothing calls this directly
no test coverage detected