com php-src: Add EXPECTF: ext/mysqli/tests/mysqli_stmt_mult ires.phpt

From: Date: Wed, 06 Aug 2014 12:27:29 +0000
Subject: com php-src: Add EXPECTF: ext/mysqli/tests/mysqli_stmt_mult ires.phpt
Groups: php.cvs 
Request: Send a blank email to php-cvs+get-79764@lists.php.net to get a copy of this message
Commit: d72b943262fd7233b28bbb51265da34b688f9f8a Author: Andrey Hristov <andrey@php.net> Wed, 6 Aug 2014 15:27:29 +0300 Parents: 9444bc79973f4eb5c76adf2b46b7802205d900bf Branches: PHP-5.4 PHP-5.5 PHP-5.6 master Link: http://git.php.net/?p=php-src.git;a=commitdiff;h=d72b943262fd7233b28bbb51265da34b688f9f8a Log: Add EXPECTF Changed paths: M ext/mysqli/tests/mysqli_stmt_multires.phpt Diff: diff --git a/ext/mysqli/tests/mysqli_stmt_multires.phpt b/ext/mysqli/tests/mysqli_stmt_multires.phpt index cce9f8d..28cf5e3 100644 --- a/ext/mysqli/tests/mysqli_stmt_multires.phpt +++ b/ext/mysqli/tests/mysqli_stmt_multires.phpt @@ -48,37 +48,42 @@ require_once('skipifconnectfailure.inc'); printf("[007] Shouldn't have fetched anything\n"); var_dump($c_id, $c_label); } + + if ($stmt->fetch()) { + printf("[008] No more rows expected\n"); + } + if (!$stmt->more_results()) { - printf("[008] Expected more results\n"); + printf("[009] Expected more results\n"); } else { - var_dump("next_result:", $stmt->next_result()); + var_dump("[009] next_result:", $stmt->next_result()); } if (!$stmt->bind_result($c_id, $c_label)) { - printf("[004] [%d] %s\n", $stmt->error, $stmt->errno); + printf("[010] [%d] %s\n", $stmt->error, $stmt->errno); } var_dump("pre:",$c_id, $c_label); if (!$stmt->fetch()) { - printf("[009] [%d] %s\n", $stmt->error, $stmt->errno); + printf("[011] [%d] %s\n", $stmt->error, $stmt->errno); } var_dump("post:",$c_id, $c_label); - if (!$stmt->more_results()) { - printf("[010] Expected more results\n"); - } else { - var_dump("next_result:", $stmt->next_result()); + if ($stmt->fetch()) { + printf("[012] No more rows expected\n"); } if (!$stmt->more_results()) { - printf("[010] Expected more results\n"); + printf("[013] Expected more results\n"); } else { - var_dump("next_result:", $stmt->next_result()); + var_dump("[013] next_result:", $stmt->next_result()); } if ($stmt->more_results()) { - printf("[011] No more results expected\n"); + printf("[014] No more results expected\n"); + } else { + printf("[014] No result, as expected\n"); } $stmt->close(); @@ -95,4 +100,21 @@ require_once('skipifconnectfailure.inc'); } ?> --EXPECTF-- -done +string(4) "pre:" +NULL +NULL +string(5) "post:" +int(13) +string(6) "a-ahoi" +string(18) "[009] next_result:" +bool(true) +string(4) "pre:" +int(13) +string(6) "a-ahoi" +string(5) "post:" +int(43) +string(5) "a---a" +string(18) "[013] next_result:" +bool(true) +[014] No result, as expected +done \ No newline at end of file

« previous php.cvs (#79764) next »