diff --git a/core/modules/search/tests/Drupal/search/Tests/SearchPageRepositoryTest.php b/core/modules/search/tests/Drupal/search/Tests/SearchPageRepositoryTest.php index 82309e7..b054b71 100644 --- a/core/modules/search/tests/Drupal/search/Tests/SearchPageRepositoryTest.php +++ b/core/modules/search/tests/Drupal/search/Tests/SearchPageRepositoryTest.php @@ -267,9 +267,13 @@ public function testSetDefaultSearchPage() { * Tests the sortSearchPages() method. */ public function testSortSearchPages() { + $entity_type = $this->getMock('Drupal\Core\Entity\EntityTypeInterface'); + $entity_type->expects($this->any()) + ->method('getClass') + ->will($this->returnValue('Drupal\search\Tests\TestSearchPage')); $this->storage->expects($this->once()) ->method('entityInfo') - ->will($this->returnValue(array('class' => 'Drupal\search\Tests\TestSearchPage'))); + ->will($this->returnValue($entity_type)); // Declare entities out of their expected order so we can be sure they were // sorted. We cannot mock these because of uasort(), see