You are here

public function HtmlFilterTest::titleConfigurationDataProvider in Search API 8

Data provider for testTitleConfiguration().

Return value

array An array of argument arrays for testTitleConfiguration().

File

tests/src/Unit/Processor/HtmlFilterTest.php, line 65

Class

HtmlFilterTest
Tests the "HTML filter" processor.

Namespace

Drupal\Tests\search_api\Unit\Processor

Code

public function titleConfigurationDataProvider() {
  return [
    [
      'word',
      'word',
      FALSE,
    ],
    [
      'word',
      'word',
      TRUE,
    ],
    [
      '<div>word</div>',
      'word',
      TRUE,
    ],
    [
      '<div title="TITLE">word</div>',
      'TITLE word',
      TRUE,
    ],
    [
      '<div title="TITLE">word</div>',
      'word',
      FALSE,
    ],
    [
      '<div data-title="TITLE">word</div>',
      'word',
      TRUE,
    ],
    [
      '<div title="TITLE">word</a>',
      'TITLE word',
      TRUE,
    ],
  ];
}