You are here

public function PlaceholderGeneratorTest::providerCreatePlaceholderGeneratesValidHtmlMarkup in Zircon Profile 8

Same name and namespace in other branches
  1. 8.0 core/tests/Drupal/Tests/Core/Render/PlaceholderGeneratorTest.php \Drupal\Tests\Core\Render\PlaceholderGeneratorTest::providerCreatePlaceholderGeneratesValidHtmlMarkup()

Return value

array

File

core/tests/Drupal/Tests/Core/Render/PlaceholderGeneratorTest.php, line 48
Contains \Drupal\Tests\Core\Render\PlaceholderGeneratorTest.

Class

PlaceholderGeneratorTest
@coversDefaultClass \Drupal\Core\Render\PlaceholderGenerator @group Render

Namespace

Drupal\Tests\Core\Render

Code

public function providerCreatePlaceholderGeneratesValidHtmlMarkup() {
  return [
    'multiple-arguments' => [
      [
        '#lazy_builder' => [
          'Drupal\\Tests\\Core\\Render\\PlaceholdersTest::callback',
          [
            'foo',
            'bar',
          ],
        ],
      ],
    ],
    'special-character-&' => [
      [
        '#lazy_builder' => [
          'Drupal\\Tests\\Core\\Render\\PlaceholdersTest::callback',
          [
            'foo&bar',
          ],
        ],
      ],
    ],
    'special-character-"' => [
      [
        '#lazy_builder' => [
          'Drupal\\Tests\\Core\\Render\\PlaceholdersTest::callback',
          [
            'foo"bar',
          ],
        ],
      ],
    ],
    'special-character-<' => [
      [
        '#lazy_builder' => [
          'Drupal\\Tests\\Core\\Render\\PlaceholdersTest::callback',
          [
            'foo<bar',
          ],
        ],
      ],
    ],
    'special-character->' => [
      [
        '#lazy_builder' => [
          'Drupal\\Tests\\Core\\Render\\PlaceholdersTest::callback',
          [
            'foo>bar',
          ],
        ],
      ],
    ],
  ];
}