mirror of
https://github.com/php/php-src.git
synced 2024-10-21 00:12:34 +00:00
caf3e9c3f1
Bug #44352 mysqli_connect_error() false negative for host errors From now on the mysqli object doesn't have that magic properties, like error, which were readable but not visible through isset(), property_exists() and var_dump(). All other ext/mysqli classes were fixed too. Now it will be easier to debug mysqli based applications.
95 lines
2.0 KiB
PHP
95 lines
2.0 KiB
PHP
--TEST--
|
|
Interface of the class mysqli_driver - Reflection
|
|
--SKIPIF--
|
|
<?php
|
|
require_once('skipif.inc');
|
|
require_once('skipifemb.inc');
|
|
require_once('connect.inc');
|
|
if (($tmp = substr(PHP_VERSION, 0, strpos(PHP_VERSION, '.'))) && ($tmp < 5))
|
|
die("skip Reflection not available before PHP 5 (found PHP $tmp)");
|
|
|
|
/*
|
|
Let's not deal with cross-version issues in the EXPECTF/UEXPECTF.
|
|
Most of the things which we test are covered by mysqli_class_*_interface.phpt.
|
|
Those tests go into the details and are aimed to be a development tool, no more.
|
|
*/
|
|
if (!$IS_MYSQLND)
|
|
die("skip Test has been written for the latest version of mysqlnd only");
|
|
if ($MYSQLND_VERSION < 576)
|
|
die("skip Test requires mysqlnd Revision 576 or newer");
|
|
?>
|
|
--FILE--
|
|
<?php
|
|
require_once('reflection_tools.inc');
|
|
$class = new ReflectionClass('mysqli_driver');
|
|
inspectClass($class);
|
|
print "done!";
|
|
?>
|
|
--EXPECTF--
|
|
Inspecting class 'mysqli_driver'
|
|
isInternal: yes
|
|
isUserDefined: no
|
|
isInstantiable: yes
|
|
isInterface: no
|
|
isAbstract: no
|
|
isFinal: yes
|
|
isIteratable: no
|
|
Modifiers: '%d'
|
|
Parent Class: ''
|
|
Extension: 'mysqli'
|
|
|
|
Inspecting property 'client_info'
|
|
isPublic: yes
|
|
isPrivate: no
|
|
isProtected: no
|
|
isStatic: no
|
|
isDefault: yes
|
|
Modifiers: 256
|
|
|
|
Inspecting property 'client_version'
|
|
isPublic: yes
|
|
isPrivate: no
|
|
isProtected: no
|
|
isStatic: no
|
|
isDefault: yes
|
|
Modifiers: 256
|
|
|
|
Inspecting property 'driver_version'
|
|
isPublic: yes
|
|
isPrivate: no
|
|
isProtected: no
|
|
isStatic: no
|
|
isDefault: yes
|
|
Modifiers: 256
|
|
|
|
Inspecting property 'embedded'
|
|
isPublic: yes
|
|
isPrivate: no
|
|
isProtected: no
|
|
isStatic: no
|
|
isDefault: yes
|
|
Modifiers: 256
|
|
|
|
Inspecting property 'reconnect'
|
|
isPublic: yes
|
|
isPrivate: no
|
|
isProtected: no
|
|
isStatic: no
|
|
isDefault: yes
|
|
Modifiers: 256
|
|
|
|
Inspecting property 'report_mode'
|
|
isPublic: yes
|
|
isPrivate: no
|
|
isProtected: no
|
|
isStatic: no
|
|
isDefault: yes
|
|
Modifiers: 256
|
|
Default property 'client_info'
|
|
Default property 'client_version'
|
|
Default property 'driver_version'
|
|
Default property 'embedded'
|
|
Default property 'reconnect'
|
|
Default property 'report_mode'
|
|
done!
|