<?php

declare(strict_types=1);

use App\Support\References\ReferenceResolutionState;

it('tracks degraded and linkable states consistently', function (ReferenceResolutionState $state, bool $isDegraded, bool $isLinkable): void {
    expect($state->isDegraded())->toBe($isDegraded)
        ->and($state->isLinkable())->toBe($isLinkable);
})->with([
    [ReferenceResolutionState::Resolved, false, true],
    [ReferenceResolutionState::PartiallyResolved, true, true],
    [ReferenceResolutionState::Unresolved, true, false],
    [ReferenceResolutionState::DeletedOrMissing, true, false],
    [ReferenceResolutionState::Inaccessible, true, false],
    [ReferenceResolutionState::ExternalLimitedContext, true, false],
]);
