mirror of
https://github.com/phpbb/phpbb.git
synced 2025-06-27 21:58:52 +00:00
[ticket/13538] Fix tests for pagination in nested loop
PHPBB3-13538
This commit is contained in:
parent
7014d824f0
commit
ee03b4f1ef
2 changed files with 7 additions and 2 deletions
|
@ -177,6 +177,11 @@ class phpbb_pagination_pagination_test extends phpbb_template_template_test_case
|
||||||
*/
|
*/
|
||||||
public function test_generate_template_pagination_sub($base_url, $start_name, $num_items, $per_page, $start_item, $expect)
|
public function test_generate_template_pagination_sub($base_url, $start_name, $num_items, $per_page, $start_item, $expect)
|
||||||
{
|
{
|
||||||
|
// Block needs to be assigned before pagination
|
||||||
|
$this->template->assign_block_vars('sub', array(
|
||||||
|
'FOO' => 'bar',
|
||||||
|
));
|
||||||
|
|
||||||
$this->pagination->generate_template_pagination($base_url, 'sub.pagination', $start_name, $num_items, $per_page, $start_item);
|
$this->pagination->generate_template_pagination($base_url, 'sub.pagination', $start_name, $num_items, $per_page, $start_item);
|
||||||
$this->template->set_filenames(array('test' => 'pagination_sub.html'));
|
$this->template->set_filenames(array('test' => 'pagination_sub.html'));
|
||||||
|
|
||||||
|
|
|
@ -11,7 +11,7 @@ pagination
|
||||||
<!-- ELSE -->:else:{sub.pagination.PAGE_NUMBER}:{sub.pagination.PAGE_URL}
|
<!-- ELSE -->:else:{sub.pagination.PAGE_NUMBER}:{sub.pagination.PAGE_URL}
|
||||||
<!-- ENDIF -->
|
<!-- ENDIF -->
|
||||||
<!-- END pagination -->
|
<!-- END pagination -->
|
||||||
<!-- IF U_PREVIOUS_PAGE -->:u_prev:{sub.U_PREVIOUS_PAGE}<!-- ENDIF -->
|
<!-- IF sub.U_PREVIOUS_PAGE -->:u_prev:{sub.U_PREVIOUS_PAGE}<!-- ENDIF -->
|
||||||
|
|
||||||
<!-- IF U_NEXT_PAGE -->:u_next:{sub.U_NEXT_PAGE}<!-- ENDIF -->
|
<!-- IF sub.U_NEXT_PAGE -->:u_next:{sub.U_NEXT_PAGE}<!-- ENDIF -->
|
||||||
<!-- END sub -->
|
<!-- END sub -->
|
||||||
|
|
Loading…
Add table
Reference in a new issue