MCPcopy Index your code
hub / github.com/AI45Lab/Code / test_engine_fire_skill_unload

Function test_engine_fire_skill_unload

core/src/hooks/engine.rs:725–736  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

723
724 #[tokio::test]
725 async fn test_engine_fire_skill_unload() {
726 let engine = HookEngine::new();
727
728 // Register a hook for skill unload events
729 engine.register(Hook::new("skill-unload-hook", HookEventType::SkillUnload));
730 engine.register_handler("skill-unload-hook", Arc::new(ContinueHandler));
731
732 let event = make_skill_unload_event("my-skill", vec!["tool1", "tool2"]);
733 let result = engine.fire(&event).await;
734
735 assert!(result.is_continue());
736 }
737
738 #[tokio::test]
739 async fn test_engine_skill_hook_with_matcher() {

Callers

nothing calls this directly

Calls 4

register_handlerMethod · 0.80
make_skill_unload_eventFunction · 0.70
registerMethod · 0.45
fireMethod · 0.45

Tested by

no test coverage detected