toBeInstanceOf(BadgeSpec::class); expect($spec->label)->toBe('Unknown'); expect($spec->color)->toBe('gray'); }); it('defines the allowed Filament badge colors', function (): void { expect(BadgeSpec::allowedColors())->toBe([ 'gray', 'info', 'success', 'warning', 'danger', 'primary', ]); }); it('carries taxonomy metadata on first-slice badge specs', function (): void { $spec = BadgeCatalog::spec(BadgeDomain::BaselineSnapshotFidelity, 'unsupported'); expect($spec->semanticAxis)->toBe(OperatorSemanticAxis::ProductSupportMaturity) ->and($spec->classification)->toBe(OperatorStateClassification::Diagnostic) ->and($spec->diagnosticLabel)->toBe('Fallback renderer'); }); it('registers inventory coverage state badge mappings centrally', function (): void { expect(BadgeCatalog::mapper(BadgeDomain::InventoryCoverageState))->not->toBeNull() ->and(BadgeCatalog::spec(BadgeDomain::InventoryCoverageState, 'failed')->label)->toBe('Failed'); }); it('keeps lifecycle badges on the shared boolean-enabled domain instead of legacy provider domains', function (): void { $domainValues = collect(BadgeDomain::cases()) ->map(fn (BadgeDomain $domain): string => $domain->value) ->all(); expect(BadgeCatalog::mapper(BadgeDomain::BooleanEnabled))->not->toBeNull() ->and($domainValues)->not->toContain('provider_connection.status', 'provider_connection.health'); });