This commit is contained in:
Robin Appelman 2016-07-13 12:23:44 +02:00
parent e5d7612a19
commit b288c6796a
1 changed files with 8 additions and 8 deletions

View File

@ -57,7 +57,7 @@ class SetupTest extends \Test\TestCase {
->method('is_callable') ->method('is_callable')
->will($this->returnValue(false)); ->will($this->returnValue(false));
$this->setupClass $this->setupClass
->expects($this->once()) ->expects($this->any())
->method('getAvailableDbDriversForPdo') ->method('getAvailableDbDriversForPdo')
->will($this->returnValue([])); ->will($this->returnValue([]));
$result = $this->setupClass->getSupportedDatabases(); $result = $this->setupClass->getSupportedDatabases();
@ -76,15 +76,15 @@ class SetupTest extends \Test\TestCase {
array('sqlite', 'mysql', 'oci', 'pgsql') array('sqlite', 'mysql', 'oci', 'pgsql')
)); ));
$this->setupClass $this->setupClass
->expects($this->once()) ->expects($this->any())
->method('class_exists') ->method('class_exists')
->will($this->returnValue(false)); ->will($this->returnValue(false));
$this->setupClass $this->setupClass
->expects($this->exactly(2)) ->expects($this->any())
->method('is_callable') ->method('is_callable')
->will($this->returnValue(false)); ->will($this->returnValue(false));
$this->setupClass $this->setupClass
->expects($this->once()) ->expects($this->any())
->method('getAvailableDbDriversForPdo') ->method('getAvailableDbDriversForPdo')
->will($this->returnValue([])); ->will($this->returnValue([]));
$result = $this->setupClass->getSupportedDatabases(); $result = $this->setupClass->getSupportedDatabases();
@ -100,17 +100,17 @@ class SetupTest extends \Test\TestCase {
array('sqlite', 'mysql', 'pgsql', 'oci') array('sqlite', 'mysql', 'pgsql', 'oci')
)); ));
$this->setupClass $this->setupClass
->expects($this->once()) ->expects($this->any())
->method('class_exists') ->method('class_exists')
->will($this->returnValue(true)); ->will($this->returnValue(true));
$this->setupClass $this->setupClass
->expects($this->exactly(2)) ->expects($this->any())
->method('is_callable') ->method('is_callable')
->will($this->returnValue(true)); ->will($this->returnValue(true));
$this->setupClass $this->setupClass
->expects($this->once()) ->expects($this->any())
->method('getAvailableDbDriversForPdo') ->method('getAvailableDbDriversForPdo')
->will($this->returnValue(['mysql'])); ->will($this->returnValue(['mysql', 'pgsql']));
$result = $this->setupClass->getSupportedDatabases(); $result = $this->setupClass->getSupportedDatabases();
$expectedResult = array( $expectedResult = array(
'sqlite' => 'SQLite', 'sqlite' => 'SQLite',