'custom', 'settings' => [], 'warnings' => [], ]; } public function flattenForDiff(?array $snapshot, string $policyType, ?string $platform = null): array { return ['custom' => true]; } }; $normalizer = new PolicyNormalizer($defaultNormalizer, [$customNormalizer]); $custom = $normalizer->normalize(['id' => 'policy-1'], 'deviceCompliancePolicy', 'windows'); expect($custom['status'])->toBe('custom'); $customDiff = $normalizer->flattenForDiff(['id' => 'policy-1'], 'deviceCompliancePolicy', 'windows'); expect($customDiff)->toBe(['custom' => true]); $fallback = $normalizer->normalize(['id' => 'policy-1'], 'unknownPolicy', 'windows'); expect($fallback['status'])->not->toBe('custom'); });