Fix PConfiguration tests

- Replace uid = 0 (invalid uid) with 42
- Remove isConnected mocked calls for invalid uid test
This commit is contained in:
Hypolite Petovan 2019-07-16 00:19:04 -04:00
parent cf70d0beb4
commit ea6b02a1f5
3 changed files with 16 additions and 33 deletions

View file

@ -116,15 +116,6 @@ class JitPConfigurationTest extends PConfigurationTest
parent::testGetWithRefresh($uid, $data);
}
public function testGetWrongWithoutDB()
{
$this->configModel->shouldReceive('isConnected')
->andReturn(false)
->times(3);
parent::testGetWrongWithoutDB();
}
/**
* @dataProvider dataTests
*/
@ -145,7 +136,7 @@ class JitPConfigurationTest extends PConfigurationTest
// mocking one get without result
$this->configModel->shouldReceive('get')
->with(0, 'test', 'it')
->with(42, 'test', 'it')
->andReturn(null)
->once();