You are here

public function ValidationResultTest::testCreateWarningResultException in Automatic Updates 8.2

@covers ::createWarning

File

tests/src/Unit/ValidationResultTest.php, line 42

Class

ValidationResultTest
@coversDefaultClass \Drupal\automatic_updates\Validation\ValidationResult

Namespace

Drupal\Tests\automatic_updates\Unit

Code

public function testCreateWarningResultException() : void {
  $this
    ->expectException(\InvalidArgumentException::class);
  $this
    ->expectExceptionMessage('If more than one message is provided, a summary is required.');
  ValidationResult::createWarning([
    'Something is wrong',
    'Something else is also wrong',
  ], NULL);
}