summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMorris Jobke <hey@morrisjobke.de>2018-07-25 16:57:36 +0200
committerMorris Jobke <hey@morrisjobke.de>2018-07-25 16:57:36 +0200
commit801e5a4523f700fde4d3137d7a0418d99d15b58a (patch)
tree94c4b6dcf83581e1c1807423d33b352a7c466fc9
parent6686ca9b2a222bc972252d86e39c7a0ced62f158 (diff)
downloadnextcloud-server-801e5a4523f700fde4d3137d7a0418d99d15b58a.tar.gz
nextcloud-server-801e5a4523f700fde4d3137d7a0418d99d15b58a.zip
Fix unit tests to pass the folder now via the appData dependency
Signed-off-by: Morris Jobke <hey@morrisjobke.de>
-rw-r--r--tests/lib/Template/SCSSCacherTest.php10
1 files changed, 8 insertions, 2 deletions
diff --git a/tests/lib/Template/SCSSCacherTest.php b/tests/lib/Template/SCSSCacherTest.php
index 149222f6b8e..2389d8ec881 100644
--- a/tests/lib/Template/SCSSCacherTest.php
+++ b/tests/lib/Template/SCSSCacherTest.php
@@ -259,7 +259,10 @@ class SCSSCacherTest extends \Test\TestCase {
$folder = $this->createMock(ISimpleFolder::class);
$folder->expects($this->at(0))->method('getFile')->with($fileNameCSS)->willThrowException(new NotFoundException());
- $actual = self::invokePrivate($this->scssCacher, 'isCached', [$fileNameCSS, $folder]);
+ $this->appData->expects($this->any())
+ ->method('getFolder')
+ ->willReturn($folder);
+ $actual = self::invokePrivate($this->scssCacher, 'isCached', [$fileNameCSS, 'core']);
$this->assertFalse($actual);
}
@@ -280,7 +283,10 @@ class SCSSCacherTest extends \Test\TestCase {
}
}));
- $actual = self::invokePrivate($this->scssCacher, 'isCached', [$fileNameCSS, $folder]);
+ $this->appData->expects($this->any())
+ ->method('getFolder')
+ ->willReturn($folder);
+ $actual = self::invokePrivate($this->scssCacher, 'isCached', [$fileNameCSS, 'core']);
$this->assertFalse($actual);
}
public function testCacheNoFile() {