function HtmlTagTest::testPreRenderConditionalComments
Same name and namespace in other branches
- 8.9.x core/tests/Drupal/Tests/Core/Render/Element/HtmlTagTest.php \Drupal\Tests\Core\Render\Element\HtmlTagTest::testPreRenderConditionalComments()
@group legacy
@covers ::preRenderConditionalComments
@dataProvider providerPreRenderConditionalComments
File
-
core/
tests/ Drupal/ Tests/ Core/ Render/ Element/ HtmlTagTest.php, line 219
Class
- HtmlTagTest
- @coversDefaultClass \Drupal\Core\Render\Element\HtmlTag[[api-linebreak]] @group Render
Namespace
Drupal\Tests\Core\Render\ElementCode
public function testPreRenderConditionalComments($element, $expected, $set_safe = FALSE) {
if ($set_safe) {
$element['#prefix'] = Markup::create($element['#prefix']);
$element['#suffix'] = Markup::create($element['#suffix']);
}
$this->assertEquals($expected, HtmlTag::preRenderConditionalComments($element));
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.