fix: lit-content-create mit divi auf einer Website ohne Divi verlangt keine Fähigkeiten – execute() antwortet mit unsupported (Divi 5 ist nicht aktiv) statt divi_incompatible samt refused-Eintrag

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
Jan-Niclas Loosen
2026-10-18 22:48:23 +02:00
co-authored by Claude Opus 5.5
parent 39143c01d0
commit 56947e54cf
4 changed files with 36 additions and 2 deletions
@@ -103,6 +103,18 @@ final class ContentCreateDiviTest extends TestCase
self::assertSame([], $this->ability(null)->requirements(self::INPUT), 'no composer: the call is refused anyway');
}
public function testRequirementsAreEmptyWhenTheComposerIsUnavailable(): void
{
$composer = $this->composer(available: false);
$composer->shouldNotReceive('requirements');
self::assertSame(
[],
$this->ability($composer)->requirements(self::INPUT),
'Divi inactive: execute() answers unsupported ("Divi 5 ist nicht aktiv"), the gate must not refuse first'
);
}
public function testRequirementsWithDiviAreThoseOfTheComposer(): void
{
$composer = $this->composer();