area); self::assertSame( [ 'GlobalPreset::get_data()', 'GlobalPreset::prepare_data()', 'GlobalPreset::validate_preset_count()', 'GlobalPreset::get_deleted_preset_ids()', 'GlobalPreset::remove_preset_from_legacy_option()', 'GlobalPreset::save_data()', 'Conversion::get_preset_attrs_mapping()', 'Conversion::get_preset_attrs()', 'GlobalPreset::get_group_preset_default_attr()', 'ModuleRegistration::get_module_settings()', 'UserRole::can_current_user_use_visual_builder()', ], array_map(static fn (Call $call): string => $call->label(), $manifest->calls) ); self::assertSame(['preset-sync'], array_map(static fn ($mirror): string => $mirror->id, $manifest->mirrors)); self::assertSame('GlobalPresetController', $manifest->mirrors[0]->class); } public function testWritesNeedAReleasedDivi(): void { ReleaseGate::useResolver(static fn (): ReleaseStatus => new ReleaseStatus(ReleaseState::Untested, '5.16.0')); $this->expectException(DiviLocked::class); (new DesignSystemWriter())->savePresets(['module' => [], 'group' => []], false); } public function testWithoutDiviNobodyUsesTheVisualBuilder(): void { self::assertFalse((new DesignSystemWriter())->canUseVisualBuilder()); } public function testWithoutDiviAModuleHasNoGroups(): void { self::assertSame([], (new DesignSystemWriter())->groupsOf('divi/button')); } }