function LayoutBuilderEntityViewDisplayTest::createEntity
Overrides EntityViewDisplayTest::createEntity
File
-
core/
modules/ layout_builder/ tests/ src/ Functional/ Jsonapi/ LayoutBuilderEntityViewDisplayTest.php, line 29
Class
- LayoutBuilderEntityViewDisplayTest
- JSON:API integration test for the "EntityViewDisplay" config entity type.
Namespace
Drupal\Tests\layout_builder\Functional\JsonapiCode
protected function createEntity() {
/** @var \Drupal\layout_builder\Entity\LayoutBuilderEntityViewDisplay $entity */
$entity = parent::createEntity();
$entity->enableLayoutBuilder()
->setOverridable()
->save();
$this->assertCount(1, $entity->getThirdPartySetting('layout_builder', 'sections'));
return $entity;
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.