public function TransliterationTest::testTransliterationWithInteger in Search API 8
Tests that integers are not affected.
File
- tests/
src/ Unit/ Processor/ TransliterationTest.php, line 54
Class
- TransliterationTest
- Tests the "Transliteration" processor.
Namespace
Drupal\Tests\search_api\Unit\ProcessorCode
public function testTransliterationWithInteger() {
$field_value = 5;
/** @var \Drupal\search_api\Item\FieldInterface $field */
$items = $this
->createSingleFieldItem($this->index, 'int', $field_value, $field);
$this->processor
->preprocessIndexItems($items);
$this
->assertEquals([
$field_value,
], $field
->getValues(), 'Integer not affected by transliteration.');
}