diff options
author | Thomas Müller <thomas.mueller@tmit.eu> | 2015-03-16 09:58:41 +0100 |
---|---|---|
committer | Thomas Müller <thomas.mueller@tmit.eu> | 2015-03-16 09:58:41 +0100 |
commit | 69277736483ad3352f82ba882977e3767884ac49 (patch) | |
tree | 97ed7ae504898962423740cfe5506126d892d18a /tests | |
parent | b159c7f27404c639f06aac2d0188f0dd59575ff1 (diff) | |
parent | 80ef53eff09886efcbe983c1db383fc5290b2048 (diff) | |
download | nextcloud-server-69277736483ad3352f82ba882977e3767884ac49.tar.gz nextcloud-server-69277736483ad3352f82ba882977e3767884ac49.zip |
Merge pull request #14776 from owncloud/fix-14629-master
verify the file name length not to exceed 255 characters + verify path d...
Diffstat (limited to 'tests')
-rw-r--r-- | tests/lib/files/pathverificationtest.php | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/tests/lib/files/pathverificationtest.php b/tests/lib/files/pathverificationtest.php index 1a802a48f57..5d38c6291a6 100644 --- a/tests/lib/files/pathverificationtest.php +++ b/tests/lib/files/pathverificationtest.php @@ -23,6 +23,16 @@ class PathVerification extends \Test\TestCase { } /** + * @expectedException \OCP\Files\InvalidPathException + * @expectedExceptionMessage File name is too long + */ + public function testPathVerificationFileNameTooLong() { + $fileName = str_repeat('a', 500); + $this->view->verifyPath('', $fileName); + } + + + /** * @dataProvider providesEmptyFiles * @expectedException \OCP\Files\InvalidPathException * @expectedExceptionMessage Empty filename is not allowed |