You are here

public function TwigExtensionTest::providerTestSetFilter in Components! 3.x

Same name and namespace in other branches
  1. 8.2 tests/src/Kernel/TwigExtensionTest.php \Drupal\Tests\components\Kernel\TwigExtensionTest::providerTestSetFilter()

Data provider for testSetFilter().

See also

testSetFilter()

File

tests/src/Kernel/TwigExtensionTest.php, line 133

Class

TwigExtensionTest
@coversDefaultClass \Drupal\components\Template\TwigExtension @group components

Namespace

Drupal\Tests\components\Kernel

Code

public function providerTestSetFilter() : array {
  return [
    'Uses positional arguments' => [
      'theme_hook' => 'components_twig_extension_test_set_filter',
      'expected' => '<div class="new-class"></div>',
    ],
    'Uses named arguments' => [
      'theme_hook' => 'components_twig_extension_test_set_filter_named_arguments',
      'expected' => '<div class="new-class"></div>',
    ],
  ];
}