public function BlockTest::testBuildOverride in Drupal 10
Same name and namespace in other branches
- 8 core/modules/views/tests/src/Unit/Plugin/views/display/BlockTest.php \Drupal\Tests\views\Unit\Plugin\views\display\BlockTest::testBuildOverride()
- 9 core/modules/views/tests/src/Unit/Plugin/views/display/BlockTest.php \Drupal\Tests\views\Unit\Plugin\views\display\BlockTest::testBuildOverride()
Tests the build method with overriding items per page.
File
- core/
modules/ views/ tests/ src/ Unit/ Plugin/ views/ display/ BlockTest.php, line 78
Class
- BlockTest
- @coversDefaultClass \Drupal\views\Plugin\views\display\Block @group block
Namespace
Drupal\Tests\views\Unit\Plugin\views\displayCode
public function testBuildOverride() {
$this->executable
->expects($this
->once())
->method('setItemsPerPage')
->with(5);
$this->blockPlugin
->expects($this
->once())
->method('getConfiguration')
->will($this
->returnValue([
'items_per_page' => 5,
]));
$this->blockDisplay
->preBlockBuild($this->blockPlugin);
}