function CategorizingPluginManagerTraitTest::testGetGroupedDefinitions
Same name in other branches
- 9 core/tests/Drupal/Tests/Core/Plugin/CategorizingPluginManagerTraitTest.php \Drupal\Tests\Core\Plugin\CategorizingPluginManagerTraitTest::testGetGroupedDefinitions()
- 10 core/tests/Drupal/Tests/Core/Plugin/CategorizingPluginManagerTraitTest.php \Drupal\Tests\Core\Plugin\CategorizingPluginManagerTraitTest::testGetGroupedDefinitions()
- 11.x core/tests/Drupal/Tests/Core/Plugin/CategorizingPluginManagerTraitTest.php \Drupal\Tests\Core\Plugin\CategorizingPluginManagerTraitTest::testGetGroupedDefinitions()
@covers ::getGroupedDefinitions
File
-
core/
tests/ Drupal/ Tests/ Core/ Plugin/ CategorizingPluginManagerTraitTest.php, line 67
Class
- CategorizingPluginManagerTraitTest
- @coversDefaultClass \Drupal\Core\Plugin\CategorizingPluginManagerTrait @group Plugin
Namespace
Drupal\Tests\Core\PluginCode
public function testGetGroupedDefinitions() {
$grouped = $this->pluginManager
->getGroupedDefinitions();
$this->assertSame([
'fruits',
'vegetables',
], array_keys($grouped));
$this->assertSame([
'apple',
'mango',
], array_keys($grouped['fruits']));
$this->assertSame([
'cucumber',
], array_keys($grouped['vegetables']));
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.