function DefaultSingleLazyPluginCollectionTest::testGetInstanceIds
Same name in other branches
- 9 core/tests/Drupal/Tests/Core/Plugin/DefaultSingleLazyPluginCollectionTest.php \Drupal\Tests\Core\Plugin\DefaultSingleLazyPluginCollectionTest::testGetInstanceIds()
- 8.9.x core/tests/Drupal/Tests/Core/Plugin/DefaultSingleLazyPluginCollectionTest.php \Drupal\Tests\Core\Plugin\DefaultSingleLazyPluginCollectionTest::testGetInstanceIds()
- 11.x core/tests/Drupal/Tests/Core/Plugin/DefaultSingleLazyPluginCollectionTest.php \Drupal\Tests\Core\Plugin\DefaultSingleLazyPluginCollectionTest::testGetInstanceIds()
@covers ::getInstanceIds
File
-
core/
tests/ Drupal/ Tests/ Core/ Plugin/ DefaultSingleLazyPluginCollectionTest.php, line 67
Class
- DefaultSingleLazyPluginCollectionTest
- @coversDefaultClass \Drupal\Core\Plugin\DefaultSingleLazyPluginCollection @group Plugin
Namespace
Drupal\Tests\Core\PluginCode
public function testGetInstanceIds() : void {
$this->setupPluginCollection($this->any());
$this->assertEquals([
'apple' => 'apple',
], $this->defaultPluginCollection
->getInstanceIds());
$this->defaultPluginCollection
->addInstanceId('banana', [
'id' => 'banana',
'key' => 'other_value',
]);
$this->assertEquals([
'banana' => 'banana',
], $this->defaultPluginCollection
->getInstanceIds());
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.