Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nextcloud/server.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJohn Molakvoæ <skjnldsv@users.noreply.github.com>2021-10-22 12:42:30 +0300
committerGitHub <noreply@github.com>2021-10-22 12:42:30 +0300
commit0a359376628b36256aa8332d79b1af1dfc513ce8 (patch)
treebc200632f14ebe2c6bfb4ec31dabee8c4fe1b49c /tests/lib/Files
parentaef40c7cf485c48c7c9e8af96c419264cc5c5a10 (diff)
parentd58d6199d980ce234b04aa2e892061d622507b5b (diff)
Merge pull request #26347 from J0WI/clean-path-regex
Diffstat (limited to 'tests/lib/Files')
-rw-r--r--tests/lib/Files/FilesystemTest.php27
1 files changed, 22 insertions, 5 deletions
diff --git a/tests/lib/Files/FilesystemTest.php b/tests/lib/Files/FilesystemTest.php
index 5859bc2c772..8f34860d85a 100644
--- a/tests/lib/Files/FilesystemTest.php
+++ b/tests/lib/Files/FilesystemTest.php
@@ -140,11 +140,26 @@ class FilesystemTest extends \Test\TestCase {
['/foo/.bar', '/foo/.bar/'],
['/foo/.bar/', '/foo/.bar/', false],
['/foo/.bar/tee', '/foo/.bar/tee'],
-
- ['/foo/bar', '/.///././//./foo/.///././//./bar/./././.'],
- ['/foo/bar/', '/.///././//./foo/.///././//./bar/./././.', false],
- ['/foo/bar', '/.///././//./foo/.///././//./bar/././././'],
- ['/foo/bar/', '/.///././//./foo/.///././//./bar/././././', false],
+ ['/foo/bar.', '/foo/bar./'],
+ ['/foo/bar./', '/foo/bar./', false],
+ ['/foo/bar./tee', '/foo/bar./tee'],
+ ['/foo/.bar.', '/foo/.bar./'],
+ ['/foo/.bar./', '/foo/.bar./', false],
+ ['/foo/.bar./tee', '/foo/.bar./tee'],
+
+ ['/foo/bar', '/.////././//./foo/.///././//./bar/././/./.'],
+ ['/foo/bar/', '/.////././//./foo/.///././//./bar/./././.', false],
+ ['/foo/bar', '/.////././//./foo/.///././//./bar/././/././'],
+ ['/foo/bar/', '/.////././//./foo/.///././//./bar/././/././', false],
+ ['/foo/.bar', '/.////././//./foo/./././/./.bar/././/././'],
+ ['/foo/.bar/', '/.////././//./foo/./././/./.bar/././/././', false],
+ ['/foo/.bar/tee./', '/.////././//./foo/./././/./.bar/tee././/././', false],
+ ['/foo/bar.', '/.////././//./foo/./././/./bar./././/././'],
+ ['/foo/bar./', '/.////././//./foo/./././/./bar./././/././', false],
+ ['/foo/bar./tee./', '/.////././//./foo/./././/./bar./tee././/././', false],
+ ['/foo/.bar.', '/.////././//./foo/./././/./.bar./././/././'],
+ ['/foo/.bar./', '/.////././//./foo/./././/./.bar./././././', false],
+ ['/foo/.bar./tee./', '/.////././//./foo/./././/./.bar./tee././././', false],
// Windows paths
['/', ''],
@@ -186,7 +201,9 @@ class FilesystemTest extends \Test\TestCase {
// normalize does not resolve '..' (by design)
['/foo/..', '/foo/../'],
+ ['/foo/../bar', '/foo/../bar/.'],
['/foo/..', '\\foo\\..\\'],
+ ['/foo/../bar', '\\foo\\..\\bar'],
];
}