aboutsummaryrefslogtreecommitdiffstats
path: root/tests/viewonline/helper_test.php
diff options
context:
space:
mode:
authorJoas Schilling <nickvergessen@gmx.de>2014-07-08 17:53:06 +0200
committerJoas Schilling <nickvergessen@gmx.de>2014-07-08 17:53:06 +0200
commit633a5177915682492f90499ebb53fc0d87c15785 (patch)
treeaf7c78a6270a76f6a32c98a2df960582de781958 /tests/viewonline/helper_test.php
parent80f8c550f9c4bdc393a673c402c846c1f8de0bb9 (diff)
downloadforums-633a5177915682492f90499ebb53fc0d87c15785.tar
forums-633a5177915682492f90499ebb53fc0d87c15785.tar.gz
forums-633a5177915682492f90499ebb53fc0d87c15785.tar.bz2
forums-633a5177915682492f90499ebb53fc0d87c15785.tar.xz
forums-633a5177915682492f90499ebb53fc0d87c15785.zip
[ticket/12834] Fix tests to match what we want to have
PHPBB3-12834
Diffstat (limited to 'tests/viewonline/helper_test.php')
-rw-r--r--tests/viewonline/helper_test.php12
1 files changed, 8 insertions, 4 deletions
diff --git a/tests/viewonline/helper_test.php b/tests/viewonline/helper_test.php
index e4950bb51a..2c903c6b23 100644
--- a/tests/viewonline/helper_test.php
+++ b/tests/viewonline/helper_test.php
@@ -23,17 +23,21 @@ class phpbb_viewonline_helper_test extends phpbb_test_case
public function session_pages_data()
{
return array(
- array('index.php', 'index.php'),
- array('foobar/test.php', 'foobar/test.php'),
+ array('index.php', 'index'),
+ array('foobar/test.php', 'foobar/test'),
array('', ''),
- array('../index.php', '../index.php'),
+ array('./../../index.php', '../../index'),
+ array('../subdir/index.php', '../subdir/index'),
+ array('../index.php', '../index'),
+ array('././index.php', 'index'),
+ array('./index.php', 'index'),
);
}
/**
* @dataProvider session_pages_data
*/
- public function test_get_user_page($expected, $session_page)
+ public function test_get_user_page($session_page, $expected)
{
$on_page = $this->viewonline_helper->get_user_page($session_page);
$this->assertArrayHasKey(1, $on_page);