()
| 1170 | |
| 1171 | #[test] |
| 1172 | fn test_add_hook_to_matcher_new() { |
| 1173 | let mut matchers = Vec::new(); |
| 1174 | add_hook_to_matcher( |
| 1175 | &mut matchers, |
| 1176 | "", |
| 1177 | "atomic agent hooks gemini-cli session-start", |
| 1178 | Some("atomic-session-start"), |
| 1179 | ); |
| 1180 | |
| 1181 | assert_eq!(matchers.len(), 1); |
| 1182 | assert_eq!(matchers[0].hooks.len(), 1); |
| 1183 | assert_eq!( |
| 1184 | matchers[0].hooks[0].command, |
| 1185 | "atomic agent hooks gemini-cli session-start" |
| 1186 | ); |
| 1187 | assert_eq!( |
| 1188 | matchers[0].hooks[0].name.as_deref(), |
| 1189 | Some("atomic-session-start") |
| 1190 | ); |
| 1191 | } |
| 1192 | |
| 1193 | #[test] |
| 1194 | fn test_add_hook_to_matcher_existing() { |
nothing calls this directly
no test coverage detected