aboutsummaryrefslogtreecommitdiffstats
path: root/tests/path_helper
diff options
context:
space:
mode:
authorJakub Senko <jakubsenko@gmail.com>2014-09-04 17:56:48 +0200
committerJakub Senko <jakubsenko@gmail.com>2014-09-04 17:56:48 +0200
commit7b796532dfbdccbca9ad66e1e752950e0c9e84b0 (patch)
treebd456cc6257f61e8596d6e4b854284421c549b1f /tests/path_helper
parent1d4cae9ecb08bcb55919a28895f68026b0539e4a (diff)
downloadforums-7b796532dfbdccbca9ad66e1e752950e0c9e84b0.tar
forums-7b796532dfbdccbca9ad66e1e752950e0c9e84b0.tar.gz
forums-7b796532dfbdccbca9ad66e1e752950e0c9e84b0.tar.bz2
forums-7b796532dfbdccbca9ad66e1e752950e0c9e84b0.tar.xz
forums-7b796532dfbdccbca9ad66e1e752950e0c9e84b0.zip
[ticket/12852] Add unit tests
PHPBB3-12852
Diffstat (limited to 'tests/path_helper')
-rw-r--r--tests/path_helper/path_helper_test.php27
1 files changed, 27 insertions, 0 deletions
diff --git a/tests/path_helper/path_helper_test.php b/tests/path_helper/path_helper_test.php
index 27e94d6a07..3832307897 100644
--- a/tests/path_helper/path_helper_test.php
+++ b/tests/path_helper/path_helper_test.php
@@ -205,6 +205,18 @@ class phpbb_path_helper_test extends phpbb_test_case
array('test' => 'xyz', 'var' => 'value'),
'test=xyz&amp;var=value',
),
+ array(
+ array('test' => null),
+ 'test',
+ ),
+ array(
+ array('test' => null, 'var' => null),
+ 'test&amp;var',
+ ),
+ array(
+ array('test' => 'xyz', 'var' => null, 'bar' => 'value'),
+ 'test=xyz&amp;var&amp;bar=value',
+ ),
);
}
@@ -254,6 +266,21 @@ class phpbb_path_helper_test extends phpbb_test_case
true,
array('base' => 'mcp.php', 'params' => array('f' => '3')),
),
+ array(
+ 'index.php?ready',
+ false,
+ array('base' => 'index.php', 'params' => array('ready' => null)),
+ ),
+ array(
+ 'index.php?i=1&amp;ready',
+ true,
+ array('base' => 'index.php', 'params' => array('i' => '1', 'ready' => null)),
+ ),
+ array(
+ 'index.php?ready&i=1',
+ false,
+ array('base' => 'index.php', 'params' => array('ready' => null, 'i' => '1')),
+ ),
);
}