]> git.mxchange.org Git - friendica.git/commitdiff
Fighting with the tests
authorMichael <heluecht@pirati.ca>
Sun, 25 Jul 2021 04:56:40 +0000 (04:56 +0000)
committerMichael <heluecht@pirati.ca>
Sun, 25 Jul 2021 04:56:40 +0000 (04:56 +0000)
tests/src/App/ModuleTest.php
tests/src/App/RouterTest.php

index 9b9bdd0cc3dcb816e53e9b30deb934651cd3beaa..730d1d886311365058dfbf314c02dd2e3ba338a5 100644 (file)
@@ -184,6 +184,8 @@ class ModuleTest extends DatabaseTest
                $cache->shouldReceive('set')->withAnyArgs()->andReturn(false)->atMost()->twice();
 
                $lock = Mockery::mock(ILock::class);
+               $lock->shouldReceive('acquire')->andReturn(true);
+               $lock->shouldReceive('isLocked')->andReturn(false);
 
                $router = (new App\Router([], __DIR__ . '/../../../static/routes.config.php', $l10n, $cache, $lock));
 
index 987df5ff9cceff62f8a0819c5487a8c60098de78..3a3c0469b4f810a59cb03ec754aefa864ba48d02 100644 (file)
@@ -57,8 +57,8 @@ class RouterTest extends TestCase
                $this->cache->shouldReceive('set')->andReturn(false);
 
                $this->lock = Mockery::mock(ILock::class);
-               $this->cache->shouldReceive('acquire')->andReturn(true);
-               $this->cache->shouldReceive('isLocked')->andReturn(false);
+               $this->lock->shouldReceive('acquire')->andReturn(true);
+               $this->lock->shouldReceive('isLocked')->andReturn(false);
        }
 
        public function testGetModuleClass()