You are here

public function PatternBaseTest::testHookLibraryInfoBuild in UI Patterns 8

Test hookLibraryInfoBuild.

@dataProvider hookLibraryInfoBuildDataProvider

@covers ::getLibraryDefinitions

File

tests/src/Kernel/Plugin/PatternBaseTest.php, line 22

Class

PatternBaseTest
@coversDefaultClass \Drupal\ui_patterns\Plugin\PatternBase

Namespace

Drupal\Tests\ui_patterns\Kernel\Plugin

Code

public function testHookLibraryInfoBuild($actual, $expected) {
  $pattern = $this
    ->getUiPatternBaseMock($actual);

  /** @var \Drupal\ui_patterns\Plugin\PatternBase $pattern */
  $libraries = $pattern
    ->getLibraryDefinitions();
  $this
    ->assertEquals($expected, $libraries);
}