public function TextFieldTest::testProcessFilteredTextFieldValues in Drupal 10
Same name and namespace in other branches
- 8 core/modules/text/tests/src/Unit/Plugin/migrate/field/d6/TextFieldTest.php \Drupal\Tests\text\Unit\Plugin\migrate\field\d6\TextFieldTest::testProcessFilteredTextFieldValues()
- 9 core/modules/text/tests/src/Unit/Plugin/migrate/field/d6/TextFieldTest.php \Drupal\Tests\text\Unit\Plugin\migrate\field\d6\TextFieldTest::testProcessFilteredTextFieldValues()
@covers ::defineValueProcessPipeline
File
- core/
modules/ text/ tests/ src/ Unit/ Plugin/ migrate/ field/ d6/ TextFieldTest.php, line 52
Class
- TextFieldTest
- @coversDefaultClass \Drupal\text\Plugin\migrate\field\d6\TextField @group text
Namespace
Drupal\Tests\text\Unit\Plugin\migrate\field\d6Code
public function testProcessFilteredTextFieldValues($method = 'defineValueProcessPipeline') {
$field_info = [
'widget_type' => 'text_textfield',
];
$this->plugin
->{$method}($this->migration, 'body', $field_info);
$process = $this->migration
->getProcess();
$this
->assertSame('sub_process', $process['plugin']);
$this
->assertSame('body', $process['source']);
$this
->assertSame('value', $process['process']['value']);
// Ensure that filter format IDs will be looked up in the filter format
// migrations.
$lookup = $process['process']['format'][2];
$this
->assertSame('migration_lookup', $lookup['plugin']);
$this
->assertContains('d6_filter_format', $lookup['migration']);
$this
->assertContains('d7_filter_format', $lookup['migration']);
$this
->assertSame('format', $lookup['source']);
}