refactor: Übergangs-API der Gesamtsperre entfernt (assertWritable, writable, refusal, writeFeatures, released); DiviLocked verlangt die gesperrten Fähigkeiten, Tests bauen Zustände über ReleaseMatrices
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Opus 5.5
parent
c036a92b60
commit
d0d3488df8
@@ -15,6 +15,7 @@ use LIT\MCP\Integrations\Divi\Release\ReleaseState;
|
||||
use LIT\MCP\Integrations\Divi\Release\ReleaseStatus;
|
||||
use LIT\MCP\Tests\Support\FeatureFakeTool;
|
||||
use LIT\MCP\Tests\Support\MatrixFixtures;
|
||||
use LIT\MCP\Tests\Support\ReleaseMatrices;
|
||||
use LIT\MCP\Tests\Unit\TestCase;
|
||||
use Mockery;
|
||||
|
||||
@@ -83,14 +84,7 @@ final class DiviEnvironmentComponentTest extends TestCase
|
||||
'auto',
|
||||
'Seiten: Signatur von et_pb_x() geändert'
|
||||
);
|
||||
ReleaseGate::useResolver(static fn (): ReleaseStatus => new ReleaseStatus(
|
||||
ReleaseState::Incompatible,
|
||||
'5.3.0',
|
||||
null,
|
||||
[],
|
||||
null,
|
||||
matrix: $matrix
|
||||
));
|
||||
ReleaseGate::useResolver(static fn (): ReleaseStatus => ReleaseStatus::of('5.3.0', $matrix));
|
||||
$overview = new FeatureOverview(static fn (): array => [
|
||||
new FeatureFakeTool('lit/divi-outline', true, [DiviFeature::PageRead]),
|
||||
new FeatureFakeTool('lit/divi-insert', true, [DiviFeature::PageRead, DiviFeature::PageWrite]),
|
||||
@@ -119,7 +113,7 @@ final class DiviEnvironmentComponentTest extends TestCase
|
||||
ReleaseGate::useResolver(static function () use (&$calls): ReleaseStatus {
|
||||
++$calls;
|
||||
|
||||
return ReleaseStatus::released('5.3.0');
|
||||
return ReleaseMatrices::released('5.3.0');
|
||||
});
|
||||
$component = new DiviEnvironmentComponent(new DiviCompatibility([]));
|
||||
|
||||
|
||||
Reference in New Issue
Block a user