You are here

public function EntityEventTest::testCommentEvent in Hook Event Dispatcher 8

Test a BlockPreprocessEvent.

File

tests/src/Unit/Preprocess/EntityEventTest.php, line 61

Class

EntityEventTest
Class EntityEventTest.

Namespace

Drupal\Tests\hook_event_dispatcher\Unit\Preprocess

Code

public function testCommentEvent() {
  $this->variables = [
    'comment' => new EntityMock('comment', 'bundle', 'view_mode'),
    'view_mode' => 'view_mode',
  ];
  $this
    ->createAndAssertEntityEvent(CommentPreprocessEvent::class);
}