function MigrateFieldPluginManagerTest::testNonExistentPluginExceptions
Same name in other branches
- 9 core/modules/migrate_drupal/tests/src/Kernel/MigrateFieldPluginManagerTest.php \Drupal\Tests\migrate_drupal\Kernel\MigrateFieldPluginManagerTest::testNonExistentPluginExceptions()
- 8.9.x core/modules/migrate_drupal/tests/src/Kernel/MigrateFieldPluginManagerTest.php \Drupal\Tests\migrate_drupal\Kernel\MigrateFieldPluginManagerTest::testNonExistentPluginExceptions()
- 11.x core/modules/migrate_drupal/tests/src/Kernel/MigrateFieldPluginManagerTest.php \Drupal\Tests\migrate_drupal\Kernel\MigrateFieldPluginManagerTest::testNonExistentPluginExceptions()
Tests that a PluginNotFoundException is thrown when a plugin isn't found.
@covers ::getPluginIdFromFieldType @dataProvider nonExistentPluginExceptionsData
File
-
core/
modules/ migrate_drupal/ tests/ src/ Kernel/ MigrateFieldPluginManagerTest.php, line 76
Class
- MigrateFieldPluginManagerTest
- Tests the field plugin manager.
Namespace
Drupal\Tests\migrate_drupal\KernelCode
public function testNonExistentPluginExceptions($core, $field_type) : void {
$this->expectException(PluginNotFoundException::class);
$this->expectExceptionMessage(sprintf("Plugin ID '%s' was not found.", $field_type));
$this->pluginManager
->getPluginIdFromFieldType($field_type, [
'core' => $core,
]);
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.