function LayoutRestTestBase::getDecodedContents
Same name in other branches
- 9 core/modules/layout_builder/tests/src/Functional/Rest/LayoutRestTestBase.php \Drupal\Tests\layout_builder\Functional\Rest\LayoutRestTestBase::getDecodedContents()
- 8.9.x core/modules/layout_builder/tests/src/Functional/Rest/LayoutRestTestBase.php \Drupal\Tests\layout_builder\Functional\Rest\LayoutRestTestBase::getDecodedContents()
- 11.x core/modules/layout_builder/tests/src/Functional/Rest/LayoutRestTestBase.php \Drupal\Tests\layout_builder\Functional\Rest\LayoutRestTestBase::getDecodedContents()
Gets the decoded contents.
Parameters
\Psr\Http\Message\ResponseInterface $response: The response.
Return value
array The decoded contents.
1 call to LayoutRestTestBase::getDecodedContents()
- OverrideSectionsTest::testOverrideField in core/
modules/ layout_builder/ tests/ src/ Functional/ Rest/ OverrideSectionsTest.php - Tests that the layout override field is not normalized.
File
-
core/
modules/ layout_builder/ tests/ src/ Functional/ Rest/ LayoutRestTestBase.php, line 145
Class
- LayoutRestTestBase
- Base class for Layout Builder REST tests.
Namespace
Drupal\Tests\layout_builder\Functional\RestCode
protected function getDecodedContents(ResponseInterface $response) {
return $this->serializer
->decode((string) $response->getBody(), static::$format);
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.