()
| 170 | |
| 171 | #[test] |
| 172 | fn test_policy_check_ask() { |
| 173 | let policy = PermissionPolicy::new().ask("Write(*)"); |
| 174 | |
| 175 | let decision = policy.check("Write", &json!({"file_path": "/tmp/test.txt"})); |
| 176 | assert_eq!(decision, PermissionDecision::Ask); |
| 177 | } |
| 178 | |
| 179 | #[test] |
| 180 | fn test_policy_check_default() { |