You are here

public function Porter2Pecl6::stemDataProvider in Porter-Stemmer 8

Data provider for testStem().

Return value

array Nested arrays of values to check:

  • $word
  • $stem

File

tests/src/Unit/Porter2Pecl6.php, line 38

Class

Porter2Pecl6
Tests the "PorterStemmer" implementation with PECL stem_english().

Namespace

Drupal\Tests\porterstemmer\Unit

Code

public function stemDataProvider() {
  if ($this->hasPeclStem) {
    return $this
      ->retrieveStemWords(25000);
  }
  else {
    return [
      [
        '',
        '',
      ],
    ];
  }
}