Update sqlite test for explain, attempt firebird tests on Travis CI
This commit is contained in:
parent
8d7b73a9a3
commit
c07a4fcf14
@ -1,5 +1,12 @@
|
||||
language: php
|
||||
|
||||
before_setup:
|
||||
- sudo add-apt-repository ppa:mapopa -qq
|
||||
- sudo apt-get update -qq
|
||||
- sudo apt-get install firebird2.5-classic -qq
|
||||
- sudo dpkg-reconfigure firebird2.5-classic -qq
|
||||
- sudo apt-get install php5-interbase -qq
|
||||
|
||||
php:
|
||||
- 5.2
|
||||
- 5.3
|
||||
|
@ -73,9 +73,26 @@
|
||||
|
||||
$res = $query->fetchAll(PDO::FETCH_ASSOC);
|
||||
|
||||
var_export($res);
|
||||
$expected_possibilities = array();
|
||||
|
||||
$expected = array (
|
||||
$expected_possibilities[] = array(
|
||||
array(
|
||||
'order' => '0',
|
||||
'from' => '0',
|
||||
'detail' => 'TABLE create_test USING PRIMARY KEY',
|
||||
)
|
||||
);
|
||||
|
||||
$expected_possibilities[] = array (
|
||||
array (
|
||||
'selectid' => '0',
|
||||
'order' => '0',
|
||||
'from' => '0',
|
||||
'detail' => 'SEARCH TABLE create_test USING INTEGER PRIMARY KEY (rowid>? AND rowid<?) (~60000 rows)',
|
||||
),
|
||||
);
|
||||
|
||||
$expected_possibilities[] = array (
|
||||
array (
|
||||
'selectid' => '0',
|
||||
'order' => '0',
|
||||
@ -84,6 +101,23 @@
|
||||
),
|
||||
);
|
||||
|
||||
//$this->assertEqual($expected, $res);
|
||||
$passed = FALSE;
|
||||
|
||||
// Check for a matching possibility
|
||||
foreach($expected_possibilities as $ep)
|
||||
{
|
||||
if ($res == $ep)
|
||||
{
|
||||
$this->assertTrue(TRUE);
|
||||
$passed = TRUE;
|
||||
}
|
||||
}
|
||||
|
||||
// Well, apparently not an expected possibility
|
||||
if ( ! $passed)
|
||||
{
|
||||
var_export($res);
|
||||
$this->assertTrue(FALSE);
|
||||
}
|
||||
}
|
||||
}
|
Loading…
Reference in New Issue
Block a user