You are here

protected function CommentHalJsonTestBase::getNormalizedPostEntity in Drupal 9

Same name and namespace in other branches
  1. 8 core/modules/comment/tests/src/Functional/Hal/CommentHalJsonTestBase.php \Drupal\Tests\comment\Functional\Hal\CommentHalJsonTestBase::getNormalizedPostEntity()

Returns the normalized POST entity.

Return value

array

Overrides CommentResourceTestBase::getNormalizedPostEntity

See also

::testPost

File

core/modules/comment/tests/src/Functional/Hal/CommentHalJsonTestBase.php, line 120

Class

CommentHalJsonTestBase

Namespace

Drupal\Tests\comment\Functional\Hal

Code

protected function getNormalizedPostEntity() {
  return parent::getNormalizedPostEntity() + [
    '_links' => [
      'type' => [
        'href' => $this->baseUrl . '/rest/type/comment/comment',
      ],
    ],
  ];
}