function EntityResourceTestBase::createEntity

Same name in other branches
  1. 9 core/modules/rest/tests/src/Functional/EntityResource/EntityResourceTestBase.php \Drupal\Tests\rest\Functional\EntityResource\EntityResourceTestBase::createEntity()
  2. 8.9.x core/modules/rest/tests/src/Functional/EntityResource/EntityResourceTestBase.php \Drupal\Tests\rest\Functional\EntityResource\EntityResourceTestBase::createEntity()
  3. 10 core/modules/rest/tests/src/Functional/EntityResource/EntityResourceTestBase.php \Drupal\Tests\rest\Functional\EntityResource\EntityResourceTestBase::createEntity()

Creates the entity to be tested.

Return value

\Drupal\Core\Entity\EntityInterface The entity to be tested.

1 call to EntityResourceTestBase::createEntity()
EntityResourceTestBase::setUp in core/modules/rest/tests/src/Functional/EntityResource/EntityResourceTestBase.php
49 methods override EntityResourceTestBase::createEntity()
ActionResourceTestBase::createEntity in core/modules/system/tests/src/Functional/Rest/ActionResourceTestBase.php
ActionResourceTestBase::createEntity in core/modules/action/tests/src/Functional/Rest/ActionResourceTestBase.php
Creates the entity to be tested.
BaseFieldOverrideResourceTestBase::createEntity in core/tests/Drupal/FunctionalTests/Rest/BaseFieldOverrideResourceTestBase.php
BlockContentResourceTestBase::createEntity in core/modules/block_content/tests/src/Functional/Rest/BlockContentResourceTestBase.php
BlockContentTypeResourceTestBase::createEntity in core/modules/block_content/tests/src/Functional/Rest/BlockContentTypeResourceTestBase.php

... See full list

File

core/modules/rest/tests/src/Functional/EntityResource/EntityResourceTestBase.php, line 251

Class

EntityResourceTestBase
Defines a base class for testing all entity resources.

Namespace

Drupal\Tests\rest\Functional\EntityResource

Code

protected abstract function createEntity();

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.