You are here

public function ThemesInstalledEventTest::testThemesInstalledEvent in Hook Event Dispatcher 8

Themes installed event test.

File

tests/src/Unit/Theme/ThemesInstalledEventTest.php, line 42

Class

ThemesInstalledEventTest
Class ThemesInstalledEventTest.

Namespace

Drupal\Tests\hook_event_dispatcher\Unit\Theme

Code

public function testThemesInstalledEvent() {
  $themes = [
    'classy',
    'bartik',
  ];
  hook_event_dispatcher_themes_installed($themes);

  /** @var \Drupal\hook_event_dispatcher\Event\Theme\ThemesInstalledEvent $event */
  $event = $this->manager
    ->getRegisteredEvent(HookEventDispatcherInterface::THEMES_INSTALLED);
  self::assertSame($themes, $event
    ->getThemeList());
}