Skip to content

Fix some PDO tests #11186

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 5 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 6 additions & 1 deletion ext/pdo/tests/bug_65946.phpt
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,12 @@ $db = PDOTest::factory();
$db->setAttribute(PDO::ATTR_EMULATE_PREPARES, true);
$db->exec('CREATE TABLE test(id int)');
$db->exec('INSERT INTO test VALUES(1)');
switch ($db->getAttribute(PDO::ATTR_DRIVER_NAME)) {

$database = $db->getAttribute(PDO::ATTR_DRIVER_NAME);
if ('odbc' === $database && 'MySQL' === $db->getAttribute(PDO::ATTR_SERVER_INFO))
$database = 'mysql';

switch ($database) {
case 'dblib':
$sql = 'SELECT TOP :limit * FROM test';
break;
Expand Down
2 changes: 1 addition & 1 deletion ext/pdo/tests/pdo_039.phpt
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ pdo
<?php
$dir = getenv('REDIR_TEST_DIR');
if (false == $dir) die('skip no driver');
if (str_starts_with(getenv('PDOTEST_DSN'), "firebird")) die('xfail firebird driver does not behave as expected');
if (str_starts_with(getenv('PDOTEST_DSN'), "firebird")) die('xfail firebird driver does not have empty initial errorCode');
require_once $dir . 'pdo_test.inc';
PDOTest::skip();
?>
Expand Down
2 changes: 2 additions & 0 deletions ext/pdo_dblib/tests/types.phpt
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,8 @@ function get_expected_float_string() {
case '7.0':
case '7.1':
case '7.2':
case '7.3':
case '7.4':
case '8.0':
return '10.500';
default:
Expand Down