diff --git a/core/modules/views/tests/src/Unit/ViewExecutableTest.php b/core/modules/views/tests/src/Unit/ViewExecutableTest.php index 7433758..d980f82 100644 --- a/core/modules/views/tests/src/Unit/ViewExecutableTest.php +++ b/core/modules/views/tests/src/Unit/ViewExecutableTest.php @@ -120,9 +120,12 @@ public function testGetUrlWithOverriddenUrl() { $this->assertSame($url, $this->executable->getUrl()); } + /** + * @covers ::getUrl + */ public function testGetUrlWithPathNoPlaceholders() { - $this->displayHandlers->expects($this->any()) - ->method('get') + $this->displayHandler->expects($this->any()) + ->method('getRoutedDisplay') ->willReturn($this->displayHandler); $this->displayHandlers->expects($this->any()) ->method('get') @@ -139,6 +142,8 @@ public function testGetUrlWithPathNoPlaceholders() { /** * @expectedException \InvalidArgumentException + * + * @covers ::getUrl */ public function testGetUrlWithoutRouterDisplay() { $this->displayHandler = $this->getMock('Drupal\views\Plugin\views\display\DisplayPluginInterface'); @@ -154,6 +159,9 @@ public function testGetUrlWithoutRouterDisplay() { * @covers ::getUrl */ public function testGetUrlWithPlaceholdersAndArgs() { + $this->displayHandler->expects($this->any()) + ->method('getRoutedDisplay') + ->willReturn($this->displayHandler); $this->displayHandlers->expects($this->any()) ->method('get') ->willReturn($this->displayHandler); @@ -177,6 +185,9 @@ public function testGetUrlWithPlaceholdersAndArgs() { * @covers ::getUrl */ public function testGetUrlWithPlaceholdersAndWithoutArgs() { + $this->displayHandler->expects($this->any()) + ->method('getRoutedDisplay') + ->willReturn($this->displayHandler); $this->displayHandlers->expects($this->any()) ->method('get') ->willReturn($this->displayHandler); @@ -200,6 +211,9 @@ public function testGetUrlWithPlaceholdersAndWithoutArgs() { * @covers ::getUrl */ public function testGetUrlWithPlaceholdersAndWithoutArgsAndExceptionValue() { + $this->displayHandler->expects($this->any()) + ->method('getRoutedDisplay') + ->willReturn($this->displayHandler); $this->displayHandlers->expects($this->any()) ->method('get') ->willReturn($this->displayHandler);