mirror of
https://github.com/php/php-src.git
synced 2025-08-17 06:28:50 +02:00
Fixed ext/pdo_mysql/tests/pdo_mysql_class_constants.phpt
There is a constant now which only is there when mysqli with mysqlnd and pdo_mysql was compiled at the same time, or when libmysql version > 50605. So checking for that dynamically, will fail only if there is no mysqli and no connection.
This commit is contained in:
parent
01f1894194
commit
f85ae48f4f
1 changed files with 8 additions and 0 deletions
|
@ -29,6 +29,14 @@ require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc');
|
||||||
$expected['MYSQL_ATTR_READ_DEFAULT_GROUP'] = true;
|
$expected['MYSQL_ATTR_READ_DEFAULT_GROUP'] = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (extension_loaded('mysqli') && stristr(mysqli_get_client_info(), "mysqlnd")
|
||||||
|
|| MySQLPDOTest::getClientVersion(MySQLPDOTest::factory()) > 50605) {
|
||||||
|
/* XXX the MySQL client library version isn't exposed with any
|
||||||
|
constants, the single possibility is to use the PDO::getAttribute().
|
||||||
|
This however will fail with no connection. */
|
||||||
|
$expected['MYSQL_ATTR_SERVER_PUBLIC_KEY'] = true;
|
||||||
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
TODO
|
TODO
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue