()
| 90 | // 1. Parse testdata/policy.yaml, verify structure. |
| 91 | #[test] |
| 92 | fn test_parse_policy() { |
| 93 | let path = testdata_dir().join("policy.yaml"); |
| 94 | let model = parse_policy(&path).expect("failed to parse policy"); |
| 95 | assert_eq!(model.version, 1); |
| 96 | assert!(model.network_policies.contains_key("github_api")); |
| 97 | let rule = &model.network_policies["github_api"]; |
| 98 | assert_eq!(rule.name, "github-api"); |
| 99 | assert_eq!(rule.endpoints.len(), 2); |
| 100 | assert!(rule.binaries.len() >= 4); |
| 101 | } |
| 102 | |
| 103 | // 2. Verify readable_paths. |
| 104 | #[test] |
nothing calls this directly
no test coverage detected