You are here

public function LocalTaskManagerTest::testGetTitle in Drupal 8

Tests the getTitle method.

See also

\Drupal\system\Plugin\Type\MenuLocalTaskManager::getTitle()

File

core/tests/Drupal/Tests/Core/Menu/LocalTaskManagerTest.php, line 236

Class

LocalTaskManagerTest
@coversDefaultClass \Drupal\Core\Menu\LocalTaskManager @group Menu

Namespace

Drupal\Tests\Core\Menu

Code

public function testGetTitle() {
  $menu_local_task = $this
    ->createMock('Drupal\\Core\\Menu\\LocalTaskInterface');
  $menu_local_task
    ->expects($this
    ->once())
    ->method('getTitle');
  $this->argumentResolver
    ->expects($this
    ->once())
    ->method('getArguments')
    ->with($this->request, [
    $menu_local_task,
    'getTitle',
  ])
    ->will($this
    ->returnValue([]));
  $this->manager
    ->getTitle($menu_local_task);
}