function AreaDisplayLinkTest::assertNoWarningMessages

Same name in other branches
  1. 9 core/modules/views/tests/src/Kernel/Handler/AreaDisplayLinkTest.php \Drupal\Tests\views\Kernel\Handler\AreaDisplayLinkTest::assertNoWarningMessages()
  2. 8.9.x core/modules/views/tests/src/Kernel/Handler/AreaDisplayLinkTest.php \Drupal\Tests\views\Kernel\Handler\AreaDisplayLinkTest::assertNoWarningMessages()
  3. 10 core/modules/views/tests/src/Kernel/Handler/AreaDisplayLinkTest.php \Drupal\Tests\views\Kernel\Handler\AreaDisplayLinkTest::assertNoWarningMessages()

Assert no warning messages are shown when all display are equal.

@internal

Parameters

\Drupal\views\ViewExecutable $view: The view to check.

1 call to AreaDisplayLinkTest::assertNoWarningMessages()
AreaDisplayLinkTest::testAreaDisplayLink in core/modules/views/tests/src/Kernel/Handler/AreaDisplayLinkTest.php
Tests the views area display_link handler.

File

core/modules/views/tests/src/Kernel/Handler/AreaDisplayLinkTest.php, line 383

Class

AreaDisplayLinkTest
Tests the core views_handler_area_display_link handler.

Namespace

Drupal\Tests\views\Kernel\Handler

Code

protected function assertNoWarningMessages(ViewExecutable $view) : void {
    $messenger = $this->container
        ->get('messenger');
    $view->validate();
    $this->assertCount(0, $messenger->messagesByType(MessengerInterface::TYPE_WARNING));
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.