function DefaultLazyPluginCollectionTest::testConfigurableSetConfigurationToNull

@covers ::setConfiguration @group legacy

File

core/tests/Drupal/Tests/Core/Plugin/DefaultLazyPluginCollectionTest.php, line 281

Class

DefaultLazyPluginCollectionTest
@coversDefaultClass \Drupal\Core\Plugin\DefaultLazyPluginCollection @group Plugin

Namespace

Drupal\Tests\Core\Plugin

Code

public function testConfigurableSetConfigurationToNull() : void {
    $this->setupPluginCollection($this->any());
    $this->expectDeprecation('Calling Drupal\\Core\\Plugin\\DefaultLazyPluginCollection::setConfiguration() with a non-array argument is deprecated in drupal:10.3.0 and will fail in drupal:11.0.0. See https://www.drupal.org/node/3406191');
    $this->defaultPluginCollection
        ->setConfiguration(NULL);
    $this->assertSame([], $this->defaultPluginCollection
        ->getConfiguration());
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.