Skip to content

Commit

Permalink
Fix broken tests
Browse files Browse the repository at this point in the history
Signed-off-by: Maurício Meneghini Fauth <mauriciofauth@gmail.com>
  • Loading branch information
MauricioFauth committed Feb 15, 2019
1 parent 3f6e360 commit c44d0f8
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
6 changes: 3 additions & 3 deletions libraries/classes/Dbi/DbiDummy.php
Original file line number Diff line number Diff line change
Expand Up @@ -820,7 +820,7 @@ private function init(): void
],
[
'query' => 'SELECT `TABLE_NAME` FROM `INFORMATION_SCHEMA`.`TABLES`'
. ' WHERE `TABLE_SCHEMA`=\'pma_test\' AND `TABLE_TYPE`=\'BASE TABLE\'',
. ' WHERE `TABLE_SCHEMA`=\'pma_test\' AND `TABLE_TYPE` IN (\'BASE TABLE\', \'SYSTEM VERSIONED\')',
'result' => [],
],
[
Expand Down Expand Up @@ -1280,7 +1280,7 @@ private function init(): void
],
],
[
'query' => "SHOW FULL TABLES FROM `default` WHERE `Table_type`='BASE TABLE'",
'query' => "SHOW FULL TABLES FROM `default` WHERE `Table_type`IN('BASE TABLE', 'SYSTEM VERSIONED')",
'result' => [
[
"test1",
Expand All @@ -1294,7 +1294,7 @@ private function init(): void
],
[
'query' => "SHOW FULL TABLES FROM `default` "
. "WHERE `Table_type`!='BASE TABLE'",
. "WHERE `Table_type`NOT IN('BASE TABLE', 'SYSTEM VERSIONED')",
'result' => [],
],
[
Expand Down
4 changes: 2 additions & 2 deletions libraries/classes/Sql.php
Original file line number Diff line number Diff line change
Expand Up @@ -210,9 +210,9 @@ private function resultSetContainsUniqueKey($db, $table, array $fields_meta)
foreach ($indexColumns as $indexColumnName => $dummy) {
if (in_array($indexColumnName, $resultSetColumnNames)) {
$numberFound++;
} else if (!in_array($indexColumnName, $columns)) {
} elseif (! in_array($indexColumnName, $columns)) {
$numberFound++;
} else if (strpos($columns[$indexColumnName]['Extra'], 'INVISIBLE') !== false) {
} elseif (strpos($columns[$indexColumnName]['Extra'], 'INVISIBLE') !== false) {
$numberFound++;
}
}
Expand Down

0 comments on commit c44d0f8

Please sign in to comment.