<?php

declare(strict_types=1);

use App\Support\Badges\BadgeCatalog;
use App\Support\Badges\BadgeDomain;

it('maps backup set status values to canonical badge semantics', function (): void {
    $running = BadgeCatalog::spec(BadgeDomain::BackupSetStatus, 'running');
    expect($running->label)->toBe('Running');
    expect($running->color)->toBe('info');

    $completed = BadgeCatalog::spec(BadgeDomain::BackupSetStatus, 'completed');
    expect($completed->label)->toBe('Completed');
    expect($completed->color)->toBe('success');

    $partial = BadgeCatalog::spec(BadgeDomain::BackupSetStatus, 'partial');
    expect($partial->label)->toBe('Partial');
    expect($partial->color)->toBe('warning');

    $failed = BadgeCatalog::spec(BadgeDomain::BackupSetStatus, 'failed');
    expect($failed->label)->toBe('Failed');
    expect($failed->color)->toBe('danger');
});
