aboutsummaryrefslogtreecommitdiffstats
path: root/apps/dav/tests/unit/Upload/FutureFileTest.php
diff options
context:
space:
mode:
Diffstat (limited to 'apps/dav/tests/unit/Upload/FutureFileTest.php')
-rw-r--r--apps/dav/tests/unit/Upload/FutureFileTest.php14
1 files changed, 6 insertions, 8 deletions
diff --git a/apps/dav/tests/unit/Upload/FutureFileTest.php b/apps/dav/tests/unit/Upload/FutureFileTest.php
index 750670992eb..1409df937c0 100644
--- a/apps/dav/tests/unit/Upload/FutureFileTest.php
+++ b/apps/dav/tests/unit/Upload/FutureFileTest.php
@@ -1,5 +1,6 @@
<?php
+declare(strict_types=1);
/**
* SPDX-FileCopyrightText: 2016-2024 Nextcloud GmbH and Nextcloud contributors
* SPDX-FileCopyrightText: 2016 ownCloud, Inc.
@@ -45,7 +46,7 @@ class FutureFileTest extends \Test\TestCase {
public function testDelete(): void {
$d = $this->getMockBuilder(Directory::class)
->disableOriginalConstructor()
- ->setMethods(['delete'])
+ ->onlyMethods(['delete'])
->getMock();
$d->expects($this->once())
@@ -55,7 +56,7 @@ class FutureFileTest extends \Test\TestCase {
$f->delete();
}
-
+
public function testPut(): void {
$this->expectException(\Sabre\DAV\Exception\Forbidden::class);
@@ -63,7 +64,7 @@ class FutureFileTest extends \Test\TestCase {
$f->put('');
}
-
+
public function testSetName(): void {
$this->expectException(\Sabre\DAV\Exception\Forbidden::class);
@@ -71,13 +72,10 @@ class FutureFileTest extends \Test\TestCase {
$f->setName('');
}
- /**
- * @return FutureFile
- */
- private function mockFutureFile() {
+ private function mockFutureFile(): FutureFile {
$d = $this->getMockBuilder(Directory::class)
->disableOriginalConstructor()
- ->setMethods(['getETag', 'getLastModified', 'getChildren'])
+ ->onlyMethods(['getETag', 'getLastModified', 'getChildren'])
->getMock();
$d->expects($this->any())