aboutsummaryrefslogtreecommitdiffstats
path: root/apps/files/tests
diff options
context:
space:
mode:
authorCôme Chilliet <come.chilliet@nextcloud.com>2021-10-25 16:43:09 +0200
committerCôme Chilliet <come.chilliet@nextcloud.com>2021-11-23 09:29:02 +0100
commit10dfdedcbd71c51fe3bd3532cb91762da3e84a58 (patch)
treed1fdc901881137b8d294ec9dedc14290e76338b8 /apps/files/tests
parent5cd5245ca8b7b37156476ad128131ac5abc3891c (diff)
downloadnextcloud-server-10dfdedcbd71c51fe3bd3532cb91762da3e84a58.tar.gz
nextcloud-server-10dfdedcbd71c51fe3bd3532cb91762da3e84a58.zip
Fix errors from files applications tests on PHP 8.1
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
Diffstat (limited to 'apps/files/tests')
-rw-r--r--apps/files/tests/Controller/ApiControllerTest.php4
1 files changed, 3 insertions, 1 deletions
diff --git a/apps/files/tests/Controller/ApiControllerTest.php b/apps/files/tests/Controller/ApiControllerTest.php
index af2d16699c1..73728bd6a4a 100644
--- a/apps/files/tests/Controller/ApiControllerTest.php
+++ b/apps/files/tests/Controller/ApiControllerTest.php
@@ -165,7 +165,7 @@ class ApiControllerTest extends TestCase {
$this->assertEquals($expected, $this->apiController->getThumbnail(0, 0, ''));
}
- public function testGetThumbnailInvaidImage() {
+ public function testGetThumbnailInvalidImage() {
$file = $this->createMock(File::class);
$this->userFolder->method('get')
->with($this->equalTo('unknown.jpg'))
@@ -184,6 +184,8 @@ class ApiControllerTest extends TestCase {
->with($this->equalTo('known.jpg'))
->willReturn($file);
$preview = $this->createMock(ISimpleFile::class);
+ $preview->method('getName')->willReturn('my name');
+ $preview->method('getMTime')->willReturn(42);
$this->preview->expects($this->once())
->method('getPreview')
->with($this->equalTo($file), 10, 10, true)