mirror of
https://github.com/friendica/friendica
synced 2025-04-27 19:10:11 +00:00
Fix tests (remove superfluous second parameter)
This commit is contained in:
parent
921845c3bd
commit
1c49f1169f
6 changed files with 12 additions and 27 deletions
|
@ -34,7 +34,7 @@ class InstallerTest extends MockedTest
|
|||
$dice = $dice->addRules(include __DIR__ . '/../../../static/dependencies.config.php');
|
||||
|
||||
$dice->shouldReceive('create')
|
||||
->with(\Friendica\Core\L10n\L10n::class, [])
|
||||
->with(\Friendica\Core\L10n\L10n::class)
|
||||
->andReturn($this->l10nMock);
|
||||
|
||||
DI::init($dice);
|
||||
|
|
|
@ -19,14 +19,14 @@ class SemaphoreLockTest extends LockTest
|
|||
|
||||
$app = \Mockery::mock(App::class);
|
||||
$app->shouldReceive('getHostname')->andReturn('friendica.local');
|
||||
$dice->shouldReceive('create')->with(App::class, [])->andReturn($app);
|
||||
$dice->shouldReceive('create')->with(App::class)->andReturn($app);
|
||||
|
||||
$configMock = \Mockery::mock(JitConfiguration::class);
|
||||
$configMock
|
||||
->shouldReceive('get')
|
||||
->with('system', 'temppath', NULL, false)
|
||||
->andReturn('/tmp/');
|
||||
$dice->shouldReceive('create')->with(IConfiguration::class, [])->andReturn($configMock);
|
||||
$dice->shouldReceive('create')->with(IConfiguration::class)->andReturn($configMock);
|
||||
|
||||
// @todo Because "get_temppath()" is using static methods, we have to initialize the BaseObject
|
||||
DI::init($dice);
|
||||
|
|
|
@ -15,7 +15,7 @@ class SystemTest extends TestCase
|
|||
$baseUrl = \Mockery::mock(BaseURL::class);
|
||||
$baseUrl->shouldReceive('getHostname')->andReturn('friendica.local')->once();
|
||||
$dice = \Mockery::mock(Dice::class);
|
||||
$dice->shouldReceive('create')->with(BaseURL::class, [])->andReturn($baseUrl);
|
||||
$dice->shouldReceive('create')->with(BaseURL::class)->andReturn($baseUrl);
|
||||
|
||||
DI::init($dice);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue