function ResourceTestBase::getPostDocument

Same name in other branches
  1. 9 core/modules/jsonapi/tests/src/Functional/ResourceTestBase.php \Drupal\Tests\jsonapi\Functional\ResourceTestBase::getPostDocument()
  2. 8.9.x core/modules/jsonapi/tests/src/Functional/ResourceTestBase.php \Drupal\Tests\jsonapi\Functional\ResourceTestBase::getPostDocument()
  3. 11.x core/modules/jsonapi/tests/src/Functional/ResourceTestBase.php \Drupal\Tests\jsonapi\Functional\ResourceTestBase::getPostDocument()

Returns the JSON:API POST document.

Return value

array A JSON:API request document.

See also

::testPostIndividual()

4 calls to ResourceTestBase::getPostDocument()
ResourceTestBase::doTestPatchIndividual in core/modules/jsonapi/tests/src/Functional/ResourceTestBase.php
Tests PATCHing an individual resource, plus edge cases to ensure good DX.
ResourceTestBase::doTestPostIndividual in core/modules/jsonapi/tests/src/Functional/ResourceTestBase.php
Tests POSTing an individual resource, plus edge cases to ensure good DX.
ResourceTestBase::getModifiedEntityForPostTesting in core/modules/jsonapi/tests/src/Functional/ResourceTestBase.php
Gets the normalized POST entity with random values for its unique fields.
ResourceTestBase::getPatchDocument in core/modules/jsonapi/tests/src/Functional/ResourceTestBase.php
Returns the JSON:API PATCH document.
48 methods override ResourceTestBase::getPostDocument()
ActionTest::getPostDocument in core/modules/jsonapi/tests/src/Functional/ActionTest.php
ActionTest::getPostDocument in core/modules/action/tests/src/Functional/Jsonapi/ActionTest.php
Returns the JSON:API POST document.
BaseFieldOverrideTest::getPostDocument in core/modules/jsonapi/tests/src/Functional/BaseFieldOverrideTest.php
Returns the JSON:API POST document.
BlockContentTest::getPostDocument in core/modules/jsonapi/tests/src/Functional/BlockContentTest.php
Returns the JSON:API POST document.
BlockContentTypeTest::getPostDocument in core/modules/jsonapi/tests/src/Functional/BlockContentTypeTest.php
Returns the JSON:API POST document.

... See full list

File

core/modules/jsonapi/tests/src/Functional/ResourceTestBase.php, line 461

Class

ResourceTestBase
Subclass this for every JSON:API resource type.

Namespace

Drupal\Tests\jsonapi\Functional

Code

protected abstract function getPostDocument();

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