public function DazzlerTest::getTwigDebugComment in Formdazzle! 2.x
Gets a Twig debug comment given the list of templates.
Parameters
string[] $templates: A list of template files.
Return value
\Drupal\Component\Render\MarkupInterface|string The Twig debug comment.
2 calls to DazzlerTest::getTwigDebugComment()
- DazzlerTest::providerPreRenderForm in tests/
src/ Unit/ DazzlerTest.php - Data provider for testPreRenderForm().
- DazzlerTest::providerRepeatedPreRenderFormCalls in tests/
src/ Unit/ DazzlerTest.php - Data provider for testRepeatedPreRenderFormCalls().
File
- tests/
src/ Unit/ DazzlerTest.php, line 169
Class
- DazzlerTest
- @coversDefaultClass \Drupal\formdazzle\Dazzler @group formdazzle
Namespace
Drupal\Tests\formdazzle\UnitCode
public function getTwigDebugComment(array $templates) {
return Markup::create(PHP_EOL . PHP_EOL . '<!-- THEME DEBUG -->' . PHP_EOL . '<!-- THEME HOOK: No templates found. -->' . PHP_EOL . '<!-- FILE NAME SUGGESTIONS:' . PHP_EOL . ' * ' . implode(PHP_EOL . ' * ', $templates) . PHP_EOL . '-->');
}