1
0
mirror of https://github.com/phpbb/phpbb.git synced 2025-08-16 13:44:12 +02:00

[ticket/15253] Update tests

PHPBB3-15253
This commit is contained in:
Rubén Calvo
2017-06-27 12:16:39 +02:00
parent b1755d9dac
commit 45334eadb6
4 changed files with 73 additions and 73 deletions

View File

@@ -23,25 +23,23 @@ class phpbb_filesystem_helper_clean_path_test extends phpbb_test_case
public function clean_path_data()
{
return array(
array('foo', 'foo'),
array('foo/bar', 'foo/bar'),
array('foo/bar/', 'foo/bar/'),
array('foo/./bar', 'foo/bar'),
array('foo/./././bar', 'foo/bar'),
array('foo/bar/.', 'foo/bar'),
array('./foo/bar', './foo/bar'),
array('../foo/bar', '../foo/bar'),
array('./../foo/bar', './../foo/bar'),
array('././../foo/bar', './../foo/bar'),
array('one/two/three', 'one/two/three'),
array('one/two/../three', 'one/three'),
array('one/../two/three', 'two/three'),
array('one/two/..', 'one'),
array('one/two/../', 'one/'),
array('one/two/../three/../four', 'one/four'),
array('one/two/three/../../four', 'one/four'),
);
yield ['foo', 'foo'];
yield ['foo/bar', 'foo/bar'];
yield ['foo/bar/', 'foo/bar/'];
yield ['foo/./bar', 'foo/bar'];
yield ['foo/./././bar', 'foo/bar'];
yield ['foo/bar/.', 'foo/bar'];
yield ['./foo/bar', './foo/bar'];
yield ['../foo/bar', '../foo/bar'];
yield ['./../foo/bar', './../foo/bar'];
yield ['././../foo/bar', './../foo/bar'];
yield ['one/two/three', 'one/two/three'];
yield ['one/two/../three', 'one/three'];
yield ['one/../two/three', 'two/three'];
yield ['one/two/..', 'one'];
yield ['one/two/../', 'one/'];
yield ['one/two/../three/../four', 'one/four'];
yield ['one/two/three/../../four', 'one/four'];
}
/**