/**
* {@inheritdoc}
*/
protected function setUp(): void
{ parent::
setUp();
entity_test_create_bundle('bundle_with_extra_fields'
);
$this->
installEntitySchema('entity_test'
);
$this->
installEntitySchema('user'
);
$this->
installConfig(['layout_builder_defaults_test'
]);
$definition =
(new SectionStorageDefinition()) ->
addContextDefinition('display', EntityContextDefinition::
fromEntityTypeId('entity_view_display'
)) ->
addContextDefinition('view_mode',
new ContextDefinition('string'
));
$this->plugin = DefaultsSectionStorage::
create($this->container,
[], 'defaults',
$definition);
} /**
* Tests installing defaults via config install.
*/
public function testConfigInstall() { /** @var \Drupal\layout_builder\Entity\LayoutEntityDisplayInterface $display */
$display = LayoutBuilderEntityViewDisplay::
load('entity_test.bundle_with_extra_fields.default'
);