protected function DefaultLazyPluginCollectionTest::getPluginMock in Drupal 10
Same name and namespace in other branches
- 8 core/tests/Drupal/Tests/Core/Plugin/DefaultLazyPluginCollectionTest.php \Drupal\Tests\Core\Plugin\DefaultLazyPluginCollectionTest::getPluginMock()
- 9 core/tests/Drupal/Tests/Core/Plugin/DefaultLazyPluginCollectionTest.php \Drupal\Tests\Core\Plugin\DefaultLazyPluginCollectionTest::getPluginMock()
Returns a mocked plugin object.
Parameters
string $plugin_id: The plugin ID.
array $definition: The plugin definition.
Return value
\Drupal\Component\Plugin\PluginInspectionInterface|\PHPUnit\Framework\MockObject\MockObject
Overrides LazyPluginCollectionTestBase::getPluginMock
File
- core/
tests/ Drupal/ Tests/ Core/ Plugin/ DefaultLazyPluginCollectionTest.php, line 210
Class
- DefaultLazyPluginCollectionTest
- @coversDefaultClass \Drupal\Core\Plugin\DefaultLazyPluginCollection @group Plugin
Namespace
Drupal\Tests\Core\PluginCode
protected function getPluginMock($plugin_id, array $definition) {
return new TestConfigurablePlugin($this->config[$plugin_id], $plugin_id, $definition);
}