uw Wed Oct 10 10:10:14 2007 UTC Added files: (Branch: PHP_5_3) /php-src/ext/mysqli/tests 069.phpt 070.phpt 074.phpt
Modified files: /php-src/ext/mysqli/tests 060.phpt 061.phpt 062.phpt 063.phpt 064.phpt 065.phpt 066.phpt 067.phpt 068.phpt 071.phpt 072.phpt 073.phpt Log: Last set of changes to the classical 0*.phpt - 06*.phpt/07*.phpt
http://cvs.php.net/viewvc.cgi/php-src/ext/mysqli/tests/060.phpt?r1=1.3.2.1&r2=1.3.2.1.4.1&diff_format=u Index: php-src/ext/mysqli/tests/060.phpt diff -u php-src/ext/mysqli/tests/060.phpt:1.3.2.1 php-src/ext/mysqli/tests/060.phpt:1.3.2.1.4.1 --- php-src/ext/mysqli/tests/060.phpt:1.3.2.1 Sat Oct 8 15:08:07 2005 +++ php-src/ext/mysqli/tests/060.phpt Wed Oct 10 10:10:14 2007 @@ -1,42 +1,45 @@ --TEST-- mysqli_fetch_object with classes --SKIPIF-- -<?php require_once('skipif.inc'); ?> +<?php +require_once('skipif.inc'); +require_once('skipifconnectfailure.inc'); +?> --FILE-- <?php include "connect.inc"; - + class test_class { function __construct($arg1, $arg2) { echo __METHOD__ . "($arg1,$arg2)\n"; } } - + /*** test mysqli_connect 127.0.0.1 ***/ - $link = mysqli_connect($host, $user, $passwd); + $link = mysqli_connect($host, $user, $passwd, $db, $port, $socket); - mysqli_select_db($link, "test"); + mysqli_select_db($link, $db); mysqli_query($link, "SET sql_mode=''"); - mysqli_query($link,"DROP TABLE IF EXISTS test_fetch"); - mysqli_query($link,"CREATE TABLE test_fetch(c1 smallint unsigned, - c2 smallint unsigned, - c3 smallint, - c4 smallint, - c5 smallint, - c6 smallint unsigned, - c7 smallint)"); + mysqli_query($link,"DROP TABLE IF EXISTS test_fetch"); + mysqli_query($link,"CREATE TABLE test_fetch(c1 smallint unsigned, + c2 smallint unsigned, + c3 smallint, + c4 smallint, + c5 smallint, + c6 smallint unsigned, + c7 smallint)"); - mysqli_query($link, "INSERT INTO test_fetch VALUES ( -23, 35999, NULL, -500, -9999999, -0, 0)"); + mysqli_query($link, "INSERT INTO test_fetch VALUES ( -23, 35999, NULL, -500, -9999999, -0, 0)"); - $result = mysqli_query($link, "SELECT * FROM test_bind_fetch"); + $result = mysqli_query($link, "SELECT * FROM test_fetch"); $test = mysqli_fetch_object($result, 'test_class', array(1, 2)); mysqli_free_result($result); var_dump($test); mysqli_close($link); - + echo "Done\n"; ?> --EXPECTF-- @@ -58,3 +61,22 @@ string(1) "0" } Done +--UEXPECTF-- +test_class::__construct(1,2) +object(test_class)#%d (7) { + [u"c1"]=> + unicode(1) "0" + [u"c2"]=> + unicode(5) "35999" + [u"c3"]=> + NULL + [u"c4"]=> + unicode(4) "-500" + [u"c5"]=> + unicode(6) "-32768" + [u"c6"]=> + unicode(1) "0" + [u"c7"]=> + unicode(1) "0" +} +Done http://cvs.php.net/viewvc.cgi/php-src/ext/mysqli/tests/061.phpt?r1=1.5.4.1&r2=1.5.4.1.2.1&diff_format=u Index: php-src/ext/mysqli/tests/061.phpt diff -u php-src/ext/mysqli/tests/061.phpt:1.5.4.1 php-src/ext/mysqli/tests/061.phpt:1.5.4.1.2.1 --- php-src/ext/mysqli/tests/061.phpt:1.5.4.1 Tue Dec 12 08:09:40 2006 +++ php-src/ext/mysqli/tests/061.phpt Wed Oct 10 10:10:14 2007 @@ -1,8 +1,10 @@ --TEST-- local infile handler --SKIPIF-- -<?php require_once('skipif.inc'); ?> -<?php require_once('skipifemb.inc'); ?> +<?php +require_once('skipif.inc'); +require_once('skipifconnectfailure.inc'); +?> --FILE-- <?php include "connect.inc"; @@ -11,36 +13,49 @@ $buffer = strrev(fread($fp, $buflen)); return(strlen($buffer)); } - - /*** test mysqli_real_connect 127.0.0.1 ***/ - $link = mysqli_init(); - mysqli_options($link, MYSQLI_OPT_LOCAL_INFILE, 1); - mysqli_real_connect($link, $host, $user, $passwd, "test"); + + /*** test mysqli_connect 127.0.0.1 ***/ + $link = mysqli_connect($host, $user, $passwd, $db, $port, $socket); /* create temporary file */ $filename = dirname(__FILE__) . "061.csv"; $fp = fopen($filename, "w"); - fwrite($fp, "foo;bar"); + fwrite($fp, b"foo;bar"); fclose($fp); - mysqli_query($link,"DROP TABLE IF EXISTS t_061"); - mysqli_query($link,"CREATE TABLE t_061 (c1 varchar(10), c2 varchar(10))"); + if (!mysqli_query($link,"DROP TABLE IF EXISTS t_061")) + printf("Cannot drop table: [%d] %s\n", mysqli_errno($link), mysqli_error($link)); + if (!mysqli_query($link,"CREATE TABLE t_061 (c1 varchar(10), c2 varchar(10))")) + printf("Cannot create table: [%d] %s\n", mysqli_errno($link), mysqli_error($link)); - mysqli_query($link, "LOAD DATA LOCAL INFILE '{$filename}' INTO TABLE t_061 FIELDS TERMINATED BY ';'"); + if (!mysqli_query($link, sprintf("LOAD DATA LOCAL INFILE '%s' INTO TABLE t_061 FIELDS TERMINATED BY ';'", mysqli_real_escape_string($link, $filename)))) + printf("Cannot load data: [%d] %s\n", mysqli_errno($link), mysqli_error($link)); mysqli_set_local_infile_handler($link, "my_read"); - mysqli_query($link, "LOAD DATA LOCAL INFILE '{$filename}' INTO TABLE t_061 FIELDS TERMINATED BY ';'"); + if (!mysqli_query($link, sprintf("LOAD DATA LOCAL INFILE '%s' INTO TABLE t_061 FIELDS TERMINATED BY ';'", mysqli_real_escape_string($link, $filename)))) + printf("Cannot load data using infile handler: [%d] %s\n", mysqli_errno($link), mysqli_error($link)); if ($result = mysqli_query($link, "SELECT c1,c2 FROM t_061")) { while (($row = mysqli_fetch_row($result))) { printf("%s-%s\n", $row[0], $row[1]); + printf("%s-%s\n", gettype($row[0]), gettype($row[1])); } mysqli_free_result($result); } mysqli_close($link); unlink($filename); + print "done!"; ?> --EXPECT-- foo-bar +string-string +rab-oof +string-string +done! +--UEXPECTF-- +foo-bar +unicode-unicode rab-oof +unicode-unicode +done! \ No newline at end of file http://cvs.php.net/viewvc.cgi/php-src/ext/mysqli/tests/062.phpt?r1=1.1&r2=1.1.6.1&diff_format=u Index: php-src/ext/mysqli/tests/062.phpt diff -u php-src/ext/mysqli/tests/062.phpt:1.1 php-src/ext/mysqli/tests/062.phpt:1.1.6.1 --- php-src/ext/mysqli/tests/062.phpt:1.1 Sun Dec 26 13:16:40 2004 +++ php-src/ext/mysqli/tests/062.phpt Wed Oct 10 10:10:14 2007 @@ -1,12 +1,15 @@ --TEST-- -resultset constructor +resultset constructor --SKIPIF-- -<?php require_once('skipif.inc'); ?> +<?php +require_once('skipif.inc'); +require_once('skipifconnectfailure.inc'); +?> --FILE-- <?php include "connect.inc"; - $mysql = new mysqli($host, $user, $passwd); + $mysql = new mysqli($host, $user, $passwd, $db, $port, $socket); $mysql->real_query("SELECT 'foo' FROM DUAL"); @@ -17,9 +20,17 @@ $mysql->close(); var_dump($row); + print "done!"; ?> ---EXPECT-- +--EXPECTF-- array(1) { [0]=> string(3) "foo" } +done! +--UEXPECTF-- +array(1) { + [0]=> + unicode(3) "foo" +} +done! \ No newline at end of file http://cvs.php.net/viewvc.cgi/php-src/ext/mysqli/tests/063.phpt?r1=1.1&r2=1.1.6.1&diff_format=u Index: php-src/ext/mysqli/tests/063.phpt diff -u php-src/ext/mysqli/tests/063.phpt:1.1 php-src/ext/mysqli/tests/063.phpt:1.1.6.1 --- php-src/ext/mysqli/tests/063.phpt:1.1 Sun Dec 26 13:16:40 2004 +++ php-src/ext/mysqli/tests/063.phpt Wed Oct 10 10:10:14 2007 @@ -1,12 +1,15 @@ --TEST-- resultset constructor --SKIPIF-- -<?php require_once('skipif.inc'); ?> +<?php +require_once('skipif.inc'); +require_once('skipifconnectfailure.inc'); +?> --FILE-- <?php include "connect.inc"; - $mysql = new mysqli($host, $user, $passwd); + $mysql = new mysqli($host, $user, $passwd, $db, $port, $socket); $stmt = new mysqli_stmt($mysql, "SELECT 'foo' FROM DUAL"); $stmt->execute(); @@ -19,3 +22,5 @@ ?> --EXPECT-- string(3) "foo" +--UEXPECT-- +unicode(3) "foo" http://cvs.php.net/viewvc.cgi/php-src/ext/mysqli/tests/064.phpt?r1=1.1&r2=1.1.8.1&diff_format=u Index: php-src/ext/mysqli/tests/064.phpt diff -u php-src/ext/mysqli/tests/064.phpt:1.1 php-src/ext/mysqli/tests/064.phpt:1.1.8.1 --- php-src/ext/mysqli/tests/064.phpt:1.1 Thu May 5 13:02:32 2005 +++ php-src/ext/mysqli/tests/064.phpt Wed Oct 10 10:10:14 2007 @@ -1,12 +1,15 @@ --TEST-- NULL binding --SKIPIF-- -<?php require_once('skipif.inc'); ?> +<?php +require_once('skipif.inc'); +require_once('skipifconnectfailure.inc'); +?> --FILE-- <?php include "connect.inc"; - $mysql = new mysqli($host, $user, $passwd); + $mysql = new mysqli($host, $user, $passwd, $db, $port, $socket); $stmt = new mysqli_stmt($mysql, "SELECT NULL FROM DUAL"); $stmt->execute(); http://cvs.php.net/viewvc.cgi/php-src/ext/mysqli/tests/065.phpt?r1=1.3.2.1.2.1&r2=1.3.2.1.2.1.2.1&diff_format=u Index: php-src/ext/mysqli/tests/065.phpt diff -u php-src/ext/mysqli/tests/065.phpt:1.3.2.1.2.1 php-src/ext/mysqli/tests/065.phpt:1.3.2.1.2.1.2.1 --- php-src/ext/mysqli/tests/065.phpt:1.3.2.1.2.1 Tue Dec 12 08:09:40 2006 +++ php-src/ext/mysqli/tests/065.phpt Wed Oct 10 10:10:14 2007 @@ -1,44 +1,55 @@ --TEST-- -set character set +set character set --SKIPIF-- -<?php -require_once('skipif.inc'); +<?php +require_once('skipif.inc'); +require_once('skipifconnectfailure.inc'); + if (!function_exists('mysqli_set_charset')) { die('skip mysqli_set_charset() not available'); } -if (!mysqli_set_charset($con, "gbh") && mysqli_errno($con) == 2019) { - die('skip mysql compiled without gbh charset support'); +if (unicode_semantics()) { + die('skip set character set not functional with unicode.semantics=On'); } ?> --FILE-- <?php include "connect.inc"; - $mysql = new mysqli($host, $user, $passwd); - mysqli_query($mysql, "SET sql_mode=''"); + if (!$mysql = new mysqli($host, $user, $passwd, $db, $port, $socket)) + printf("[001] [%d] %s\n", mysqli_connect_errno(), mysqli_connect_error()); + + if (!mysqli_query($mysql, "SET sql_mode=''")) + printf("[002] Cannot set SQL-Mode, [%d] %s\n", mysqli_errno($mysql), mysqli_error($mysql)); $esc_str = chr(0xbf) . chr(0x5c); + $len = $charset = array(); + $tmp = null; if ($mysql->set_charset("latin1")) { /* 5C should be escaped */ - $len[0] = strlen($mysql->real_escape_string($esc_str)); - $charset[0] = $mysql->client_encoding(); - } + if (3 !== ($tmp = strlen($mysql->real_escape_string($esc_str)))) + printf("[003] Expecting 3/int got %s/%s\n", gettype($tmp), $tmp); - if ($mysql->set_charset("gbk")) { - /* nothing should be escaped, it's a valid gbk character */ - $len[1] = strlen($mysql->real_escape_string($esc_str)); - $charset[1] = $mysql->client_encoding(); + if ('latin1' !== ($tmp = $mysql->client_encoding())) + printf("[004] Expecting latin1/string got %s/%s\n", gettype($tmp), $tmp); } + if ($res = $mysql->query("SHOW CHARACTER SET LIKE 'gbk'")) { + $res->free_result(); + if ($mysql->set_charset("gbk")) { + /* nothing should be escaped, it's a valid gbk character */ + + if (2 !== ($tmp = strlen($mysql->real_escape_string($esc_str)))) + printf("[005] Expecting 2/int got %s/%s\n", gettype($tmp), $tmp); + + if ('gbk' !== ($tmp = $mysql->client_encoding())) + printf("[005] Expecting gbk/string got %s/%s\n", gettype($tmp), $tmp);; + } + } $mysql->close(); - var_dump($len[0]); - var_dump($len[1]); - var_dump($charset[0]); - var_dump($charset[1]); + + print "done!"; ?> --EXPECT-- -int(3) -int(2) -string(6) "latin1" -string(3) "gbk" +done! \ No newline at end of file http://cvs.php.net/viewvc.cgi/php-src/ext/mysqli/tests/066.phpt?r1=1.1&r2=1.1.6.1&diff_format=u Index: php-src/ext/mysqli/tests/066.phpt diff -u php-src/ext/mysqli/tests/066.phpt:1.1 php-src/ext/mysqli/tests/066.phpt:1.1.6.1 --- php-src/ext/mysqli/tests/066.phpt:1.1 Wed Jun 22 10:15:37 2005 +++ php-src/ext/mysqli/tests/066.phpt Wed Oct 10 10:10:14 2007 @@ -1,21 +1,24 @@ --TEST-- function test: mysqli_warning object --SKIPIF-- -<?php require_once('skipif.inc'); ?> +<?php +require_once('skipif.inc'); +require_once('skipifconnectfailure.inc'); +?> --FILE-- <?php include "connect.inc"; - + /*** test mysqli_connect 127.0.0.1 ***/ - $mysql = new mysqli($host, $user, $passwd, "test"); + $mysql = new mysqli($host, $user, $passwd, $db, $port, $socket); $mysql->query("DROP TABLE IF EXISTS test_warnings"); - $mysql->query("CREATE TABLE test_warnings (a int not null)"); + $mysql->query("CREATE TABLE test_warnings (a int not null) ENGINE=myisam"); $mysql->query("INSERT INTO test_warnings VALUES (1),(2),(NULL)"); - + if (($warning = new mysqli_warning($mysql))) { do { printf("Warning\n"); @@ -23,6 +26,8 @@ } $mysql->close(); + print "done!"; ?> --EXPECT-- Warning +done! \ No newline at end of file http://cvs.php.net/viewvc.cgi/php-src/ext/mysqli/tests/067.phpt?r1=1.1&r2=1.1.6.1&diff_format=u Index: php-src/ext/mysqli/tests/067.phpt diff -u php-src/ext/mysqli/tests/067.phpt:1.1 php-src/ext/mysqli/tests/067.phpt:1.1.6.1 --- php-src/ext/mysqli/tests/067.phpt:1.1 Wed Jun 22 10:14:32 2005 +++ php-src/ext/mysqli/tests/067.phpt Wed Oct 10 10:10:14 2007 @@ -1,38 +1,55 @@ --TEST-- function test: nested selects (cursors) --SKIPIF-- -<?php - require_once('skipif.inc'); +<?php + require_once('skipif.inc'); + require_once('skipifconnectfailure.inc'); + include "connect.inc"; + + if (!$link = mysqli_connect($host, $user, $passwd, $db, $port, $socket)) + die("skip Cannot connect to check required version"); + /* skip cursor test for versions < 50004 */ - if (mysqli_get_client_version() < 50009) { - die("skip Client library doesn't support cursors"); + if ((!$IS_MYSQLND && (mysqli_get_client_version() < 50009)) || + (mysqli_get_server_version($link) < 50009)) { + die(sprintf("skip Client library doesn't support cursors (%s/%s)", + mysqli_get_client_version(), mysqli_get_server_version($link))); } + mysqli_close($link); ?> --FILE-- <?php - function open_cursor($mysql, $query) { - $stmt = $mysql->prepare($query); + if (!is_object($stmt = $mysql->prepare($query))) { + printf("[001] Cannot create statement object for '%s', [%d] %s\n", + $query, $mysql->errno, $mysql->error); + } + $stmt->attr_set(MYSQLI_STMT_ATTR_CURSOR_TYPE, MYSQLI_CURSOR_TYPE_READ_ONLY); return $stmt; } include "connect.inc"; + $mysql = new mysqli($host, $user, $passwd, $db, $port, $socket); + + if ((!$IS_MYSQLND && mysqli_get_client_version() < 50009) || + (mysqli_get_server_version($mysql) < 50009)) { + /* we really want to skip it... */ + die(var_dump(63)); + } + $a = array(); - - /*** test mysqli_connect 127.0.0.1 ***/ - $mysql = new mysqli($host, $user, $passwd, "test"); for ($i=0;$i < 3; $i++) { $mysql->query("DROP TABLE IF EXISTS cursor$i"); - $mysql->query("CREATE TABLE cursor$i (a int not null)"); + $mysql->query("CREATE TABLE cursor$i (a int not null) ENGINE=" . $engine); $mysql->query("INSERT INTO cursor$i VALUES (1),(2),(3),(4),(5),(6)"); $stmt[$i] = open_cursor($mysql, "SELECT a FROM cursor$i"); $stmt[$i]->execute(); $stmt[$i]->bind_result($a[$i]); } - + $cnt = 0; while ($stmt[0]->fetch()) { $stmt[1]->fetch(); @@ -48,4 +65,4 @@ var_dump($cnt); ?> --EXPECT-- -int(63) +int(63) \ No newline at end of file http://cvs.php.net/viewvc.cgi/php-src/ext/mysqli/tests/068.phpt?r1=1.1.2.2&r2=1.1.2.2.2.1&diff_format=u Index: php-src/ext/mysqli/tests/068.phpt diff -u php-src/ext/mysqli/tests/068.phpt:1.1.2.2 php-src/ext/mysqli/tests/068.phpt:1.1.2.2.2.1 --- php-src/ext/mysqli/tests/068.phpt:1.1.2.2 Wed Jul 12 09:51:47 2006 +++ php-src/ext/mysqli/tests/068.phpt Wed Oct 10 10:10:14 2007 @@ -1,33 +1,13 @@ --TEST-- -mysqli_autocommit() tests +mysqli get_client_info --SKIPIF-- -<?php - require_once('skipif.inc'); -?> +<?php require_once('skipif.inc'); ?> --FILE-- <?php - -include "connect.inc"; - -$mysqli = new mysqli($host, $user, $passwd, "test"); - -var_dump($mysqli->autocommit(false)); -$result = $mysqli->query("SELECT @@autocommit"); -var_dump($result->fetch_row()); - -var_dump($mysqli->autocommit(true)); -$result = $mysqli->query("SELECT @@autocommit"); -var_dump($result->fetch_row()); - + $s = mysqli_get_client_info(); + echo gettype($s); ?> --EXPECT-- -bool(true) -array(1) { - [0]=> - string(1) "0" -} -bool(true) -array(1) { - [0]=> - string(1) "1" -} +string +--UEXPECT-- +unicode http://cvs.php.net/viewvc.cgi/php-src/ext/mysqli/tests/071.phpt?r1=1.4.2.2&r2=1.4.2.2.2.1&diff_format=u Index: php-src/ext/mysqli/tests/071.phpt diff -u php-src/ext/mysqli/tests/071.phpt:1.4.2.2 php-src/ext/mysqli/tests/071.phpt:1.4.2.2.2.1 --- php-src/ext/mysqli/tests/071.phpt:1.4.2.2 Tue Jul 11 23:35:38 2006 +++ php-src/ext/mysqli/tests/071.phpt Wed Oct 10 10:10:14 2007 @@ -1,13 +1,16 @@ --TEST-- mysqli thread_id & kill --SKIPIF-- -<?php require_once('skipif.inc'); ?> -<?php require_once('skipifemb.inc'); ?> +<?php +require_once('skipif.inc'); +require_once('skipifemb.inc'); +require_once('skipifconnectfailure.inc'); +?> --FILE-- <?php include "connect.inc"; - $mysql = new mysqli($host, $user, $passwd, "test"); + $mysql = new mysqli($host, $user, $passwd, $db, $port, $socket); var_dump($mysql->ping()); @@ -17,7 +20,7 @@ $mysql->close(); - $mysql = new mysqli($host, $user, $passwd, "test"); + $mysql = new mysqli($host, $user, $passwd, $db, $port, $socket); var_dump(mysqli_ping($mysql)); @@ -26,6 +29,7 @@ var_dump(mysqli_ping($mysql)); $mysql->close(); + print "done!"; ?> --EXPECT-- bool(true) @@ -34,3 +38,4 @@ bool(true) bool(true) bool(false) +done! \ No newline at end of file http://cvs.php.net/viewvc.cgi/php-src/ext/mysqli/tests/072.phpt?r1=1.1.2.2&r2=1.1.2.2.2.1&diff_format=u Index: php-src/ext/mysqli/tests/072.phpt diff -u php-src/ext/mysqli/tests/072.phpt:1.1.2.2 php-src/ext/mysqli/tests/072.phpt:1.1.2.2.2.1 --- php-src/ext/mysqli/tests/072.phpt:1.1.2.2 Wed Jul 12 08:01:44 2006 +++ php-src/ext/mysqli/tests/072.phpt Wed Oct 10 10:10:14 2007 @@ -1,13 +1,15 @@ --TEST-- mysqli warning_count, get_warnings --SKIPIF-- -<?php require_once('skipif.inc'); ?> -<?php die('skip mysqli_warning class not functional yet?'); ?> +<?php +require_once('skipif.inc'); +require_once('skipifconnectfailure.inc'); +?> --FILE-- <?php include "connect.inc"; - $mysql = new mysqli($host, $user, $passwd, "test"); + $mysql = new mysqli($host, $user, $passwd, $db, $port, $socket); $mysql->query("DROP TABLE IF EXISTS not_exists"); @@ -17,11 +19,20 @@ var_dump($w->errno); var_dump($w->message); -# var_dump($w->sqlstate); + var_dump($w->sqlstate); $mysql->close(); + echo "done!" ?> ---EXPECT-- -1 -1051 -Unknown table 'not_exists' \ No newline at end of file +--EXPECTF-- +int(1) +int(1051) +string(26) "Unknown table 'not_exists'" +string(5) "HY000" +done! +--UEXPECTF-- +int(1) +int(1051) +unicode(26) "Unknown table 'not_exists'" +unicode(5) "HY000" +done! \ No newline at end of file http://cvs.php.net/viewvc.cgi/php-src/ext/mysqli/tests/073.phpt?r1=1.1.2.2&r2=1.1.2.2.2.1&diff_format=u Index: php-src/ext/mysqli/tests/073.phpt diff -u php-src/ext/mysqli/tests/073.phpt:1.1.2.2 php-src/ext/mysqli/tests/073.phpt:1.1.2.2.2.1 --- php-src/ext/mysqli/tests/073.phpt:1.1.2.2 Wed Jul 12 08:01:44 2006 +++ php-src/ext/mysqli/tests/073.phpt Wed Oct 10 10:10:14 2007 @@ -6,13 +6,13 @@ <?php include "connect.inc"; - var_dump( $driver->embedded); - var_dump( $driver->client_version); - var_dump( $driver->client_info); - var_dump( $driver->driver_version); - var_dump( $driver->reconnect); - var_dump( $driver->report_mode); - + var_dump($driver->embedded); + var_dump($driver->client_version); + var_dump($driver->client_info); + var_dump($driver->driver_version); + var_dump($driver->reconnect); + var_dump($driver->report_mode); + print "done!"; ?> --EXPECTF-- bool(%s) @@ -21,3 +21,12 @@ int(%d) bool(%s) int(%d) +done! +--UEXPECTF-- +bool(%s) +int(%d) +unicode(%d) "%s" +int(%d) +bool(%s) +int(%d) +done! \ No newline at end of file http://cvs.php.net/viewvc.cgi/php-src/ext/mysqli/tests/069.phpt?view=markup&rev=1.1 Index: php-src/ext/mysqli/tests/069.phpt +++ php-src/ext/mysqli/tests/069.phpt --TEST-- mysqli multi_query, next_result, more_results --SKIPIF-- <?php require_once('skipif.inc'); ?> --FILE-- <?php include "connect.inc"; $mysql = new mysqli($host, $user, $passwd, "test"); $mysql->multi_query('SELECT 1;SELECT 2'); do { $res = $mysql->store_result(); if ($mysql->errno == 0) { while ($arr = $res->fetch_assoc()) { var_dump($arr); } $res->free(); } if ($mysql->more_results()) { echo "---\n"; } } while ($mysql->next_result()); $mysql->close(); ?> --EXPECT-- array(1) { [1]=> string(1) "1" } --- array(1) { [2]=> string(1) "2" } http://cvs.php.net/viewvc.cgi/php-src/ext/mysqli/tests/070.phpt?view=markup&rev=1.1 Index: php-src/ext/mysqli/tests/070.phpt +++ php-src/ext/mysqli/tests/070.phpt --TEST-- mysqli ping --SKIPIF-- <?php require_once('skipif.inc'); ?> --FILE-- <?php include "connect.inc"; $mysql = new mysqli($host, $user, $passwd, "test"); var_dump($mysql->ping()); $mysql->close(); ?> --EXPECT-- bool(true) http://cvs.php.net/viewvc.cgi/php-src/ext/mysqli/tests/074.phpt?view=markup&rev=1.1 Index: php-src/ext/mysqli/tests/074.phpt +++ php-src/ext/mysqli/tests/074.phpt --TEST-- mysqli_autocommit() tests --SKIPIF-- <?php require_once('skipif.inc'); ?> --FILE-- <?php include "connect.inc"; $mysqli = new mysqli($host, $user, $passwd, "test"); var_dump($mysqli->autocommit(false)); $result = $mysqli->query("SELECT @@autocommit"); var_dump($result->fetch_row()); var_dump($mysqli->autocommit(true)); $result = $mysqli->query("SELECT @@autocommit"); var_dump($result->fetch_row()); ?> --EXPECT-- bool(true) array(1) { [0]=> string(1) "0" } bool(true) array(1) { [0]=> string(1) "1" }
-- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php