function PagerPluginBaseTest::setUp
Same name in other branches
- 9 core/modules/views/tests/src/Unit/Plugin/pager/PagerPluginBaseTest.php \Drupal\Tests\views\Unit\Plugin\pager\PagerPluginBaseTest::setUp()
- 8.9.x core/modules/views/tests/src/Unit/Plugin/pager/PagerPluginBaseTest.php \Drupal\Tests\views\Unit\Plugin\pager\PagerPluginBaseTest::setUp()
- 11.x core/modules/views/tests/src/Unit/Plugin/pager/PagerPluginBaseTest.php \Drupal\Tests\views\Unit\Plugin\pager\PagerPluginBaseTest::setUp()
Overrides UnitTestCase::setUp
File
-
core/
modules/ views/ tests/ src/ Unit/ Plugin/ pager/ PagerPluginBaseTest.php, line 27
Class
- PagerPluginBaseTest
- @coversDefaultClass \Drupal\views\Plugin\views\pager\PagerPluginBase @group views
Namespace
Drupal\Tests\views\Unit\Plugin\pagerCode
protected function setUp() : void {
parent::setUp();
$this->pager = $this->getMockBuilder('Drupal\\views\\Plugin\\views\\pager\\PagerPluginBase')
->disableOriginalConstructor()
->getMockForAbstractClass();
$view = $this->getMockBuilder('Drupal\\views\\ViewExecutable')
->disableOriginalConstructor()
->getMock();
$display = $this->getMockBuilder('Drupal\\views\\Plugin\\views\\display\\DisplayPluginBase')
->disableOriginalConstructor()
->getMock();
$options = [
'items_per_page' => 5,
'offset' => 1,
];
$this->pager
->init($view, $display, $options);
$this->pager->current_page = 1;
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.