function NodeMigrationTypePluginAlterTest::testMigrationPluginAlter

Same name and namespace in other branches
  1. 10 core/modules/migrate_drupal/tests/src/Kernel/NodeMigrationTypePluginAlterTest.php \Drupal\Tests\migrate_drupal\Kernel\NodeMigrationTypePluginAlterTest::testMigrationPluginAlter()
  2. 11.x core/modules/migrate_drupal/tests/src/Kernel/NodeMigrationTypePluginAlterTest.php \Drupal\Tests\migrate_drupal\Kernel\NodeMigrationTypePluginAlterTest::testMigrationPluginAlter()
  3. 9 core/modules/migrate_drupal/tests/src/Kernel/NodeMigrationTypePluginAlterTest.php \Drupal\Tests\migrate_drupal\Kernel\NodeMigrationTypePluginAlterTest::testMigrationPluginAlter()
  4. 8.9.x core/modules/migrate_drupal/tests/src/Kernel/NodeMigrationTypePluginAlterTest.php \Drupal\Tests\migrate_drupal\Kernel\NodeMigrationTypePluginAlterTest::testMigrationPluginAlter()

Tests the assignment of the node migration type.

Attributes

#[DataProvider('providerMigrationPluginAlter')]

Parameters

string $type: The type of node migration, 'classic' or 'complete'.

array $migration_definitions: An array of migration definitions.

array $expected: The expected results.

Throws

\Exception

File

core/modules/migrate_drupal/tests/src/Kernel/NodeMigrationTypePluginAlterTest.php, line 49

Class

NodeMigrationTypePluginAlterTest
Tests the assignment of the node migration type in migrations_plugin_alter.

Namespace

Drupal\Tests\migrate_drupal\Kernel

Code

public function testMigrationPluginAlter($type, array $migration_definitions, array $expected) : void {
  $this->makeNodeMigrateMapTable($type, '7');
  $migrateDrupalMigrationPluginsAlter = new MigrateDrupalHooks();
  $migrateDrupalMigrationPluginsAlter->migrationPluginsAlter($migration_definitions);
  $this->assertSame($expected, $migration_definitions);
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.