]> git.mxchange.org Git - friendica.git/blobdiff - tests/src/App/ModuleTest.php
Merge pull request #10604 from MrPetovan/task/10603-ap-string-mentions
[friendica.git] / tests / src / App / ModuleTest.php
index 42d6fb1ef5b1328b956ab1050e24fc6e9fc678bd..730d1d886311365058dfbf314c02dd2e3ba338a5 100644 (file)
@@ -25,6 +25,7 @@ use Friendica\App;
 use Friendica\Core\Cache\ICache;
 use Friendica\Core\Config\IConfig;
 use Friendica\Core\L10n;
+use Friendica\Core\Lock\ILock;
 use Friendica\LegacyModule;
 use Friendica\Module\HTTPException\PageNotFound;
 use Friendica\Module\WellKnown\HostMeta;
@@ -182,7 +183,11 @@ class ModuleTest extends DatabaseTest
                $cache->shouldReceive('get')->with('lastRoutesFileModifiedTime')->andReturn('')->atMost()->once();
                $cache->shouldReceive('set')->withAnyArgs()->andReturn(false)->atMost()->twice();
 
-               $router = (new App\Router([], __DIR__ . '/../../../static/routes.config.php', $l10n, $cache));
+               $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));
 
                $module = (new App\Module($name))->determineClass(new App\Arguments('', $command), $router, $config);