public function LayoutBuilderEntityViewDisplayTest::testGetIndividual in Layout Builder Symmetric Translations 8
Tests GETting an individual resource, plus edge cases to ensure good DX.
Overrides ResourceTestBase::testGetIndividual
File
- tests/
src/ Functional/ Jsonapi/ LayoutBuilderEntityViewDisplayTest.php, line 26
Class
- LayoutBuilderEntityViewDisplayTest
- JSON:API integration test for the "EntityViewDisplay" config entity type.
Namespace
Drupal\Tests\layout_builder_st\Functional\JsonapiCode
public function testGetIndividual() {
$resource_type_repository = $this->container
->get('jsonapi.resource_type.repository');
$this
->assertInstanceOf(ResourceTypeRepository::class, $resource_type_repository);
// Ensure that the entity_view_display entity class has actually been
// overridden.
$entity_class = $this->container
->get('entity_type.manager')
->getDefinition('entity_view_display')
->getClass();
$this
->assertSame(LayoutBuilderEntityViewDisplay::class, $entity_class);
parent::testGetIndividual();
}