1--TEST-- 2mysqli_dump_debug_info() 3--EXTENSIONS-- 4mysqli 5--SKIPIF-- 6<?php 7require_once('skipifconnectfailure.inc'); 8?> 9--FILE-- 10<?php 11 require_once("connect.inc"); 12 13 if (!$link = my_mysqli_connect($host, $user, $passwd, $db, $port, $socket)) { 14 printf("[003] Cannot connect to the server using host=%s, user=%s, passwd=***, dbname=%s, port=%s, socket=%s\n", 15 $host, $user, $db, $port, $socket); 16 exit(1); 17 } 18 19 if (!is_bool($tmp = mysqli_dump_debug_info($link))) 20 printf("[004] Expecting boolean/[true|false] value, got %s/%s, [%d] %s\n", 21 gettype($tmp), $tmp, 22 mysqli_errno($link), mysqli_error($link)); 23 24 mysqli_close($link); 25 26 try { 27 mysqli_dump_debug_info($link); 28 } catch (Error $exception) { 29 echo $exception->getMessage() . "\n"; 30 } 31 32 print "done!"; 33?> 34--EXPECT-- 35mysqli object is already closed 36done! 37