aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorChris Smith <toonarmy@phpbb.com>2008-11-24 11:46:28 +0000
committerChris Smith <toonarmy@phpbb.com>2008-11-24 11:46:28 +0000
commitf816e67c36a01faee3e1b3e82527f2d42db9a680 (patch)
tree6db5d3cd1fcf6bc0de5024b528a4d1571e4204b5
parent528bd80651b3d11d2fd8249d2f326af59161f387 (diff)
downloadforums-f816e67c36a01faee3e1b3e82527f2d42db9a680.tar
forums-f816e67c36a01faee3e1b3e82527f2d42db9a680.tar.gz
forums-f816e67c36a01faee3e1b3e82527f2d42db9a680.tar.bz2
forums-f816e67c36a01faee3e1b3e82527f2d42db9a680.tar.xz
forums-f816e67c36a01faee3e1b3e82527f2d42db9a680.zip
Test is (even|odd) by y
git-svn-id: file:///svn/phpbb/trunk@9110 89ea8834-ac86-4346-8a33-228a782c2dd0
-rw-r--r--tests/template/template.php7
-rw-r--r--tests/template/templates/loop_expressions.html11
2 files changed, 18 insertions, 0 deletions
diff --git a/tests/template/template.php b/tests/template/template.php
index 72ad065acf..89de67a453 100644
--- a/tests/template/template.php
+++ b/tests/template/template.php
@@ -203,6 +203,13 @@ class phpbb_template_template_test extends phpbb_test_case
array('loop.inner'),
"first\n0\n0\n2\nx\nset\n1\n1\n2\ny\nset\nlast",
),
+ array(
+ 'loop_expressions.html',
+ array(),
+ array('loop' => array(array(), array(), array(), array(), array(), array(), array(), array(), array(), array(), array(), array())),
+ array(),
+ "on\non\non\non\noff\noff\noff\noff\non\non\non\non\n\noff\noff\noff\non\non\non\noff\noff\noff\non\non\non",
+ ),
);
}
diff --git a/tests/template/templates/loop_expressions.html b/tests/template/templates/loop_expressions.html
new file mode 100644
index 0000000000..6bff53f388
--- /dev/null
+++ b/tests/template/templates/loop_expressions.html
@@ -0,0 +1,11 @@
+<!-- BEGIN loop -->
+
+<!-- IF loop.S_ROW_NUM is even by 4 -->on<!-- ELSE -->off<!-- ENDIF -->
+
+<!-- END loop -->
+
+<!-- BEGIN loop -->
+
+<!-- IF loop.S_ROW_NUM is odd by 3 -->on<!-- ELSE -->off<!-- ENDIF -->
+
+<!-- END loop -->