From 094d41937a5889e4c545ecf575aa1acbcf489a55 Mon Sep 17 00:00:00 2001 From: Roeland Jago Douma Date: Mon, 18 Dec 2017 21:06:52 +0100 Subject: [PATCH] Fix tests Signed-off-by: Roeland Jago Douma --- apps/theming/tests/ThemingDefaultsTest.php | 2 +- tests/Core/Command/Maintenance/UpdateTheme.php | 2 +- tests/lib/App/AppManagerTest.php | 2 +- tests/lib/IntegrityCheck/CheckerTest.php | 2 +- tests/lib/Security/RateLimiting/Backend/MemoryCacheTest.php | 2 +- 5 files changed, 5 insertions(+), 5 deletions(-) diff --git a/apps/theming/tests/ThemingDefaultsTest.php b/apps/theming/tests/ThemingDefaultsTest.php index 52bf88e51d..843c1d34f9 100644 --- a/apps/theming/tests/ThemingDefaultsTest.php +++ b/apps/theming/tests/ThemingDefaultsTest.php @@ -78,7 +78,7 @@ class ThemingDefaultsTest extends TestCase { $this->defaults = new \OC_Defaults(); $this->cacheFactory ->expects($this->any()) - ->method('create') + ->method('createDistributed') ->with('theming') ->willReturn($this->cache); $this->template = new ThemingDefaults( diff --git a/tests/Core/Command/Maintenance/UpdateTheme.php b/tests/Core/Command/Maintenance/UpdateTheme.php index fbdea0b72b..cbc417dbdb 100644 --- a/tests/Core/Command/Maintenance/UpdateTheme.php +++ b/tests/Core/Command/Maintenance/UpdateTheme.php @@ -74,7 +74,7 @@ class UpdateThemeTest extends TestCase { ->method('clear') ->with(''); $this->cacheFactory->expects($this->once()) - ->method('create') + ->method('createDistributed') ->with('imagePath') ->willReturn($cache); self::invokePrivate($this->command, 'execute', [$this->consoleInput, $this->consoleOutput]); diff --git a/tests/lib/App/AppManagerTest.php b/tests/lib/App/AppManagerTest.php index c2c0ea5507..c361db7b76 100644 --- a/tests/lib/App/AppManagerTest.php +++ b/tests/lib/App/AppManagerTest.php @@ -100,7 +100,7 @@ class AppManagerTest extends TestCase { $this->cache = $this->createMock(ICache::class); $this->eventDispatcher = $this->createMock(EventDispatcherInterface::class); $this->cacheFactory->expects($this->any()) - ->method('create') + ->method('createDistributed') ->with('settings') ->willReturn($this->cache); $this->manager = new AppManager($this->userSession, $this->appConfig, $this->groupManager, $this->cacheFactory, $this->eventDispatcher); diff --git a/tests/lib/IntegrityCheck/CheckerTest.php b/tests/lib/IntegrityCheck/CheckerTest.php index 049017cb5e..09e6990a0f 100644 --- a/tests/lib/IntegrityCheck/CheckerTest.php +++ b/tests/lib/IntegrityCheck/CheckerTest.php @@ -60,7 +60,7 @@ class CheckerTest extends TestCase { $this->cacheFactory ->expects($this->any()) - ->method('create') + ->method('createDistributed') ->with('oc.integritycheck.checker') ->will($this->returnValue(new NullCache())); diff --git a/tests/lib/Security/RateLimiting/Backend/MemoryCacheTest.php b/tests/lib/Security/RateLimiting/Backend/MemoryCacheTest.php index 34c326e72e..bacd2b7bf6 100644 --- a/tests/lib/Security/RateLimiting/Backend/MemoryCacheTest.php +++ b/tests/lib/Security/RateLimiting/Backend/MemoryCacheTest.php @@ -46,7 +46,7 @@ class MemoryCacheTest extends TestCase { $this->cacheFactory ->expects($this->once()) - ->method('create') + ->method('createDistributed') ->with('OC\Security\RateLimiting\Backend\MemoryCache') ->willReturn($this->cache);