public function DiscoveryCachedTraitTest::providerGetDefinition in Drupal 9
Same name and namespace in other branches
- 8 core/tests/Drupal/Tests/Component/Plugin/Discovery/DiscoveryCachedTraitTest.php \Drupal\Tests\Component\Plugin\Discovery\DiscoveryCachedTraitTest::providerGetDefinition()
Data provider for testGetDefinition().
Return value
array
- Expected result from getDefinition().
- Cached definitions to be placed into self::$definitions
- Definitions to be returned by getDefinitions().
- Plugin name to query for.
File
- core/
tests/ Drupal/ Tests/ Component/ Plugin/ Discovery/ DiscoveryCachedTraitTest.php, line 23
Class
- DiscoveryCachedTraitTest
- @coversDefaultClass \Drupal\Component\Plugin\Discovery\DiscoveryCachedTrait @uses \Drupal\Component\Plugin\Discovery\DiscoveryTrait @group Plugin
Namespace
Drupal\Tests\Component\Plugin\DiscoveryCode
public function providerGetDefinition() {
return [
[
'definition',
[],
[
'plugin_name' => 'definition',
],
'plugin_name',
],
[
'definition',
[
'plugin_name' => 'definition',
],
[],
'plugin_name',
],
[
NULL,
[
'plugin_name' => 'definition',
],
[],
'bad_plugin_name',
],
];
}