fixing tests and preload config

This commit is contained in:
Philipp Holzer
2019-02-23 00:09:57 +01:00
parent 8d56fb8fbe
commit 1dee89f215
6 changed files with 12 additions and 60 deletions

View File

@@ -145,7 +145,7 @@ class PConfigurationTest extends MockedTest
$configAdapter->shouldReceive('isLoaded')->with($uid, 'test', 'it')->andReturn(true)->twice();
$configAdapter->shouldReceive('get')->with($uid, 'test', 'it')->andReturn($data)->once();
$configAdapter->shouldReceive('isLoaded')->with($uid, 'test', 'not')->andReturn(false)->once();
$configAdapter->shouldReceive('get')->with($uid, 'test', 'not')->andReturn('!<unset>!')->once();
$configAdapter->shouldReceive('get')->with($uid, 'test', 'not')->andReturn(null)->once();
$configuration = new PConfiguration($configCache, $configAdapter);
@@ -173,7 +173,7 @@ class PConfigurationTest extends MockedTest
$configAdapter->shouldReceive('isConnected')->andReturn(true)->times(3);
$configAdapter->shouldReceive('isLoaded')->with($uid, 'test', 'it')->andReturn(false)->once();
$configAdapter->shouldReceive('get')->with($uid, 'test', 'it')->andReturn('!<unset>!')->once();
$configAdapter->shouldReceive('get')->with($uid, 'test', 'it')->andReturn(null)->once();
$configAdapter->shouldReceive('isLoaded')->with($uid, 'test', 'it')->andReturn(false)->once();
$configAdapter->shouldReceive('get')->with($uid, 'test', 'it')->andReturn($data)->once();