function ExtractorTest::testLoadIconMissingData

Test the IconExtractorBase:loadIcon with missing data.

File

core/tests/Drupal/Tests/Core/Theme/Icon/Plugin/ExtractorTest.php, line 178

Class

ExtractorTest
Tests icon extractor with base and finder base plugin.

Namespace

Drupal\Tests\Core\Theme\Icon\Plugin

Code

public function testLoadIconMissingData() : void {
  $extractorPlugin = new TestExtractor([
    'id' => $this->pluginId,
    'template' => '_bar_',
  ], $this->pluginId, []);
  $icon = $extractorPlugin->loadIcon([]);
  $this->assertNull($icon);
}

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