Fighting with the tests

This commit is contained in:
Michael 2021-07-25 04:56:40 +00:00
parent 12c63c9b97
commit 52378eb298
2 changed files with 4 additions and 2 deletions

View File

@ -184,6 +184,8 @@ class ModuleTest extends DatabaseTest
$cache->shouldReceive('set')->withAnyArgs()->andReturn(false)->atMost()->twice(); $cache->shouldReceive('set')->withAnyArgs()->andReturn(false)->atMost()->twice();
$lock = Mockery::mock(ILock::class); $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)); $router = (new App\Router([], __DIR__ . '/../../../static/routes.config.php', $l10n, $cache, $lock));

View File

@ -57,8 +57,8 @@ class RouterTest extends TestCase
$this->cache->shouldReceive('set')->andReturn(false); $this->cache->shouldReceive('set')->andReturn(false);
$this->lock = Mockery::mock(ILock::class); $this->lock = Mockery::mock(ILock::class);
$this->cache->shouldReceive('acquire')->andReturn(true); $this->lock->shouldReceive('acquire')->andReturn(true);
$this->cache->shouldReceive('isLocked')->andReturn(false); $this->lock->shouldReceive('isLocked')->andReturn(false);
} }
public function testGetModuleClass() public function testGetModuleClass()