From aa15f9d16d5b46d04763c7deedb129990e819364 Mon Sep 17 00:00:00 2001 From: Robin Appelman Date: Mon, 30 Jun 2025 16:56:59 +0200 Subject: chore: run rector Signed-off-by: Robin Appelman --- tests/lib/Files/FilesystemTest.php | 19 ++++++------------- 1 file changed, 6 insertions(+), 13 deletions(-) (limited to 'tests/lib/Files/FilesystemTest.php') diff --git a/tests/lib/Files/FilesystemTest.php b/tests/lib/Files/FilesystemTest.php index 07166e098e7..a819acb1620 100644 --- a/tests/lib/Files/FilesystemTest.php +++ b/tests/lib/Files/FilesystemTest.php @@ -16,6 +16,7 @@ use OC\User\NoUserException; use OCP\Files; use OCP\Files\Config\IMountProvider; use OCP\Files\Config\IMountProviderCollection; +use OCP\Files\Mount\IMountPoint; use OCP\Files\Storage\IStorageFactory; use OCP\IConfig; use OCP\ITempManager; @@ -38,7 +39,7 @@ class DummyMountProvider implements IMountProvider { * * @param IUser $user * @param IStorageFactory $loader - * @return \OCP\Files\Mount\IMountPoint[] + * @return IMountPoint[] */ public function getMountsForUser(IUser $user, IStorageFactory $loader) { return isset($this->mounts[$user->getUID()]) ? $this->mounts[$user->getUID()] : []; @@ -201,9 +202,7 @@ class FilesystemTest extends \Test\TestCase { ]; } - /** - * @dataProvider normalizePathData - */ + #[\PHPUnit\Framework\Attributes\DataProvider('normalizePathData')] public function testNormalizePath($expected, $path, $stripTrailingSlash = true): void { $this->assertEquals($expected, Filesystem::normalizePath($path, $stripTrailingSlash)); } @@ -219,9 +218,7 @@ class FilesystemTest extends \Test\TestCase { ]; } - /** - * @dataProvider normalizePathKeepUnicodeData - */ + #[\PHPUnit\Framework\Attributes\DataProvider('normalizePathKeepUnicodeData')] public function testNormalizePathKeepUnicode($expected, $path, $keepUnicode = false): void { $this->assertEquals($expected, Filesystem::normalizePath($path, true, false, $keepUnicode)); } @@ -260,9 +257,7 @@ class FilesystemTest extends \Test\TestCase { ]; } - /** - * @dataProvider isValidPathData - */ + #[\PHPUnit\Framework\Attributes\DataProvider('isValidPathData')] public function testIsValidPath($path, $expected): void { $this->assertSame($expected, Filesystem::isValidPath($path)); } @@ -282,9 +277,7 @@ class FilesystemTest extends \Test\TestCase { ]; } - /** - * @dataProvider isFileBlacklistedData - */ + #[\PHPUnit\Framework\Attributes\DataProvider('isFileBlacklistedData')] public function testIsFileBlacklisted($path, $expected): void { $this->assertSame($expected, Filesystem::isFileBlacklisted($path)); } -- cgit v1.2.3