You are here

public function TokenTest::testTokenInvalidDescriptionException in Hook Event Dispatcher 3.x

Same name and namespace in other branches
  1. 8.2 modules/core_event_dispatcher/tests/src/Unit/Token/TokenTest.php \Drupal\Tests\core_event_dispatcher\Unit\Token\TokenTest::testTokenInvalidDescriptionException()

Test Token invalid description exception.

File

modules/core_event_dispatcher/tests/src/Unit/Token/TokenTest.php, line 27

Class

TokenTest
Class TokenTest.

Namespace

Drupal\Tests\core_event_dispatcher\Unit\Token

Code

public function testTokenInvalidDescriptionException() : void {
  $this
    ->expectException(UnexpectedValueException::class);
  Token::create('', '', '')
    ->setDescription(NULL);
}