protected function ComponentsTest::render in Components! 3.x
Same name and namespace in other branches
- 8.2 tests/src/Functional/ComponentsTest.php \Drupal\Tests\components\Functional\ComponentsTest::render()
Renders a render array.
Parameters
array $elements: The elements to render.
Return value
string The rendered string output (typically HTML).
1 call to ComponentsTest::render()
- ComponentsTest::testLoadTemplate in tests/
src/ Functional/ ComponentsTest.php - Ensures component templates can be loaded inside a Drupal instance.
File
- tests/
src/ Functional/ ComponentsTest.php, line 41
Class
- ComponentsTest
- Tests the components module in a fully loaded Drupal instance.
Namespace
Drupal\Tests\components\FunctionalCode
protected function render(array &$elements) : string {
return $this->container
->get('renderer')
->renderRoot($elements);
}