TaxonomyTermDeriverTest.php in Drupal 9
File
core/modules/taxonomy/tests/src/Kernel/Migrate/TaxonomyTermDeriverTest.php
View source
<?php
namespace Drupal\Tests\taxonomy\Kernel\Migrate;
use Drupal\Tests\migrate_drupal\Kernel\d7\MigrateDrupal7TestBase;
class TaxonomyTermDeriverTest extends MigrateDrupal7TestBase {
protected static $modules = [
'taxonomy',
'text',
];
public function testBuilder() {
$process = $this
->getMigration('d7_taxonomy_term:vocabfixed')
->getProcess();
$this
->assertSame('field_training', $process['field_training'][0]['source']);
$process = $this
->getMigration('d7_taxonomy_term:vocablocalized')
->getProcess();
$this
->assertSame('field_sector', $process['field_sector'][0]['source']);
$process = $this
->getMigration('d7_taxonomy_term:vocabtranslate')
->getProcess();
$this
->assertSame('field_chancellor', $process['field_chancellor'][0]['source']);
$process = $this
->getMigration('d7_taxonomy_term:test_vocabulary')
->getProcess();
$this
->assertSame('field_integer', $process['field_integer'][0]['source']);
$this
->assertSame('field_term_reference', $process['field_term_reference'][0]['source']);
}
}