aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--tests/pagination/pagination_test.php5
-rw-r--r--tests/pagination/templates/pagination_sub.html4
2 files changed, 7 insertions, 2 deletions
diff --git a/tests/pagination/pagination_test.php b/tests/pagination/pagination_test.php
index ca42fa806f..a37d34ad1b 100644
--- a/tests/pagination/pagination_test.php
+++ b/tests/pagination/pagination_test.php
@@ -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)
{
+ // 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->template->set_filenames(array('test' => 'pagination_sub.html'));
diff --git a/tests/pagination/templates/pagination_sub.html b/tests/pagination/templates/pagination_sub.html
index 1d87940e5d..4ec14039e0 100644
--- a/tests/pagination/templates/pagination_sub.html
+++ b/tests/pagination/templates/pagination_sub.html
@@ -11,7 +11,7 @@ pagination
<!-- ELSE -->:else:{sub.pagination.PAGE_NUMBER}:{sub.pagination.PAGE_URL}
<!-- ENDIF -->
<!-- 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 -->