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

Function test_parse_extra_fields_ignored

atomic-agent/src/hooks/sherpa.rs:644–653  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

642
643 #[test]
644 fn test_parse_extra_fields_ignored() {
645 let hook = make_hook();
646 let input = br#"{
647 "session_id": "s1",
648 "unknown_field": "whatever",
649 "another": 42
650 }"#;
651 let event = hook.parse_event(HookType::SessionStart, input).unwrap();
652 assert_eq!(event.session_id, "s1");
653 }
654
655 // --- default trait ---
656

Callers

nothing calls this directly

Calls 3

make_hookFunction · 0.70
unwrapMethod · 0.45
parse_eventMethod · 0.45

Tested by

no test coverage detected