You are here

public function MigrationPluginConfigurationTest::testConfigurationMerge in Drupal 8

Same name and namespace in other branches
  1. 9 core/modules/migrate/tests/src/Kernel/Plugin/MigrationPluginConfigurationTest.php \Drupal\Tests\migrate\Kernel\Plugin\MigrationPluginConfigurationTest::testConfigurationMerge()

Test merging configuration into a plugin through the plugin manager.

@dataProvider mergeProvider

File

core/modules/migrate/tests/src/Kernel/Plugin/MigrationPluginConfigurationTest.php, line 31

Class

MigrationPluginConfigurationTest
Tests the migration plugin manager.

Namespace

Drupal\Tests\migrate\Kernel\Plugin

Code

public function testConfigurationMerge($id, $configuration, $expected) {

  /** @var \Drupal\migrate\Plugin\MigrationInterface $migration */
  $migration = $this->container
    ->get('plugin.manager.migration')
    ->createInstance($id, $configuration);
  $source_configuration = $migration
    ->getSourceConfiguration();
  $this
    ->assertEquals($expected, $source_configuration);
}