1 views_pager.test | public ViewsPagerTest::testRenderNullPager() |
Tests rendering with NULL pager.
File
- core/
modules/ views/ tests/ views_pager.test, line 414 - Definition of ViewsPagerTest.
Class
- ViewsPagerTest
- Tests the pluggable pager system.
Code
public function testRenderNullPager() {
// Create 11 nodes and make sure that everyone is returned.
// We create 11 nodes, because the default pager plugin had 10 items per page.
for ($i = 0; $i < 11; $i++) {
$this->backdropCreateNode();
}
$view = $this->viewsPagerFullFields();
$view->set_display('default');
$this->executeView($view);
$view->use_ajax = TRUE; // force the value again here
$view->query->pager = NULL;
$output = $view->render();
$this->assertEqual(preg_match('/<ul class="pager">/', $output), 0, t('The pager is not rendered.'));
}