mirror of
https://github.com/php/php-src.git
synced 2026-03-24 00:02:20 +01:00
Remove unnecessary requires in mysqli tests
This commit is contained in:
@@ -9,7 +9,11 @@ require_once 'skipifconnectfailure.inc';
|
||||
--FILE--
|
||||
<?php
|
||||
require_once 'connect.inc';
|
||||
require 'table.inc';
|
||||
if (!$link = my_mysqli_connect($host, $user, $passwd, $db, $port, $socket)) {
|
||||
printf("Cannot connect to the server using host=%s, user=%s, passwd=***, dbname=%s, port=%s, socket=%s\n",
|
||||
$host, $user, $db, $port, $socket);
|
||||
exit(1);
|
||||
}
|
||||
|
||||
// Returns only one result set
|
||||
$link->multi_query("SELECT 1");
|
||||
@@ -24,10 +28,6 @@ require_once 'skipifconnectfailure.inc';
|
||||
|
||||
$link->close();
|
||||
?>
|
||||
--CLEAN--
|
||||
<?php
|
||||
require_once 'clean_table.inc';
|
||||
?>
|
||||
--EXPECT--
|
||||
bool(false)
|
||||
object(mysqli_result)#3 (5) {
|
||||
|
||||
@@ -8,7 +8,6 @@ require_once 'skipifconnectfailure.inc';
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
require 'connect.inc';
|
||||
require 'table.inc';
|
||||
|
||||
$mysqli = new my_mysqli($host, $user, $passwd, $db, $port, $socket);
|
||||
|
||||
@@ -8,7 +8,6 @@ mysqli
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
require 'connect.inc';
|
||||
require 'table.inc';
|
||||
|
||||
$link = my_mysqli_connect($host, $user, $passwd, $db, $port, $socket);
|
||||
|
||||
@@ -8,8 +8,6 @@ require_once 'skipifconnectfailure.inc';
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
require_once 'connect.inc';
|
||||
|
||||
require 'table.inc';
|
||||
if (!$res = mysqli_query($link, 'SELECT * FROM test ORDER BY id LIMIT 4', MYSQLI_STORE_RESULT))
|
||||
printf("[004] [%d] %s\n", mysqli_errno($link), mysqli_error($link));
|
||||
|
||||
@@ -8,7 +8,6 @@ require_once 'skipifconnectfailure.inc';
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
require_once 'connect.inc';
|
||||
require 'table.inc';
|
||||
|
||||
if (!$mysqli = new mysqli($host, $user, $passwd, $db, $port, $socket))
|
||||
|
||||
@@ -8,8 +8,6 @@ require_once 'skipifconnectfailure.inc';
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
require_once 'connect.inc';
|
||||
|
||||
require 'table.inc';
|
||||
if (!$res = mysqli_query($link, "SELECT * FROM test ORDER BY id LIMIT 2")) {
|
||||
printf("[004] [%d] %s\n", mysqli_errno($link), mysqli_error($link));
|
||||
|
||||
@@ -8,18 +8,8 @@ require_once 'skipifconnectfailure.inc';
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
require_once 'connect.inc';
|
||||
|
||||
$tmp = NULL;
|
||||
$link = NULL;
|
||||
|
||||
$mysqli = new mysqli();
|
||||
|
||||
if (!$mysqli = new my_mysqli($host, $user, $passwd, $db, $port, $socket))
|
||||
printf("[002] Cannot connect to the server using host=%s, user=%s, passwd=***, dbname=%s, port=%s, socket=%s\n",
|
||||
$host, $user, $db, $port, $socket);
|
||||
|
||||
require 'table.inc';
|
||||
$mysqli = $link;
|
||||
if (!$res = $mysqli->query("SELECT * FROM test ORDER BY id LIMIT 2")) {
|
||||
printf("[004] [%d] %s\n", $mysqli->errno, $mysqli->error);
|
||||
}
|
||||
|
||||
@@ -8,8 +8,6 @@ require_once 'skipifconnectfailure.inc';
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
require_once 'connect.inc';
|
||||
|
||||
require 'table.inc';
|
||||
if (!$res = mysqli_query($link, "SELECT * FROM test ORDER BY id LIMIT 5")) {
|
||||
printf("[004] [%d] %s\n", mysqli_errno($link), mysqli_error($link));
|
||||
|
||||
@@ -8,15 +8,8 @@ require_once 'skipifconnectfailure.inc';
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
require_once 'connect.inc';
|
||||
|
||||
$tmp = NULL;
|
||||
$link = NULL;
|
||||
|
||||
require 'table.inc';
|
||||
if (!$mysqli = new my_mysqli($host, $user, $passwd, $db, $port, $socket))
|
||||
printf("[001] Cannot connect to the server using host=%s, user=%s, passwd=***, dbname=%s, port=%s, socket=%s\n",
|
||||
$host, $user, $db, $port, $socket);
|
||||
$mysqli = $link;
|
||||
|
||||
if (!$res = $mysqli->query("SELECT * FROM test ORDER BY id LIMIT 5")) {
|
||||
printf("[004] [%d] %s\n", $mysqli->errno, $mysqli->error);
|
||||
|
||||
@@ -8,8 +8,6 @@ require_once 'skipifconnectfailure.inc';
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
require_once 'connect.inc';
|
||||
|
||||
// Note: no SQL type tests, internally the same function gets used as for mysqli_fetch_array() which does a lot of SQL type test
|
||||
|
||||
require 'table.inc';
|
||||
|
||||
@@ -34,7 +34,12 @@ mysqli
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
require 'table.inc';
|
||||
require_once 'connect.inc';
|
||||
if (!$link = my_mysqli_connect($host, $user, $passwd, $db, $port, $socket)) {
|
||||
printf("Cannot connect to the server using host=%s, user=%s, passwd=***, dbname=%s, port=%s, socket=%s\n",
|
||||
$host, $user, $db, $port, $socket);
|
||||
exit(1);
|
||||
}
|
||||
|
||||
/* some cyrillic (utf8) comes here */
|
||||
if (!$res = mysqli_query($link, "SET NAMES UTF8")) {
|
||||
@@ -77,10 +82,6 @@ mysqli
|
||||
mysqli_close($link);
|
||||
print "done!";
|
||||
?>
|
||||
--CLEAN--
|
||||
<?php
|
||||
require_once 'clean_table.inc';
|
||||
?>
|
||||
--EXPECTF--
|
||||
[003]
|
||||
array(3) {
|
||||
|
||||
@@ -8,11 +8,6 @@ require_once 'skipifconnectfailure.inc';
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
require_once 'connect.inc';
|
||||
|
||||
$tmp = NULL;
|
||||
$link = NULL;
|
||||
|
||||
// Note: no SQL type tests, internally the same function gets used as for mysqli_fetch_array() which does a lot of SQL type test
|
||||
$mysqli = new mysqli();
|
||||
try {
|
||||
@@ -22,9 +17,7 @@ require_once 'skipifconnectfailure.inc';
|
||||
}
|
||||
|
||||
require 'table.inc';
|
||||
if (!$mysqli = new my_mysqli($host, $user, $passwd, $db, $port, $socket))
|
||||
printf("[002] Cannot connect to the server using host=%s, user=%s, passwd=***, dbname=%s, port=%s, socket=%s\n",
|
||||
$host, $user, $db, $port, $socket);
|
||||
$mysqli = $link;
|
||||
|
||||
if (!$res = $mysqli->query("SELECT id, label FROM test ORDER BY id LIMIT 1")) {
|
||||
printf("[004] [%d] %s\n", $mysqli->errno, $mysqli->error);
|
||||
|
||||
@@ -8,8 +8,6 @@ require_once 'skipifconnectfailure.inc';
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
require_once 'connect.inc';
|
||||
require 'table.inc';
|
||||
mysqli_report(MYSQLI_REPORT_ERROR | MYSQLI_REPORT_STRICT);
|
||||
|
||||
|
||||
@@ -8,8 +8,6 @@ require_once 'skipifconnectfailure.inc';
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
require_once 'connect.inc';
|
||||
|
||||
// Note: no SQL type tests, internally the same function gets used as for mysqli_fetch_array() which does a lot of SQL type test
|
||||
|
||||
require 'table.inc';
|
||||
|
||||
@@ -8,8 +8,6 @@ require_once 'skipifconnectfailure.inc';
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
require_once 'connect.inc';
|
||||
|
||||
require 'table.inc';
|
||||
|
||||
if (!$res = mysqli_query($link, "SELECT id AS ID, label FROM test AS TEST ORDER BY id LIMIT 1")) {
|
||||
|
||||
@@ -8,8 +8,6 @@ require_once 'skipifconnectfailure.inc';
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
require_once 'connect.inc';
|
||||
|
||||
$mysqli = new mysqli();
|
||||
try {
|
||||
new mysqli_result($mysqli);
|
||||
@@ -18,10 +16,7 @@ require_once 'skipifconnectfailure.inc';
|
||||
}
|
||||
|
||||
require 'table.inc';
|
||||
|
||||
if (!$mysqli = new my_mysqli($host, $user, $passwd, $db, $port, $socket))
|
||||
printf("[002] Cannot connect to the server using host=%s, user=%s, passwd=***, dbname=%s, port=%s, socket=%s\n",
|
||||
$host, $user, $db, $port, $socket);
|
||||
$mysqli = $link;
|
||||
|
||||
if (!$res = $mysqli->query("SELECT id AS ID, label FROM test AS TEST ORDER BY id LIMIT 1")) {
|
||||
printf("[003] [%d] %s\n", mysqli_errno($link), mysqli_error($link));
|
||||
|
||||
@@ -8,8 +8,6 @@ require_once 'skipifconnectfailure.inc';
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
require_once 'connect.inc';
|
||||
|
||||
// Note: no SQL type tests, internally the same function gets used as for mysqli_fetch_array() which does a lot of SQL type test
|
||||
$mysqli = new mysqli();
|
||||
$res = false;
|
||||
@@ -20,9 +18,7 @@ require_once 'skipifconnectfailure.inc';
|
||||
}
|
||||
|
||||
require 'table.inc';
|
||||
if (!$mysqli = new mysqli($host, $user, $passwd, $db, $port, $socket))
|
||||
printf("[002] Cannot connect to the server using host=%s, user=%s, passwd=***, dbname=%s, port=%s, socket=%s\n",
|
||||
$host, $user, $db, $port, $socket);
|
||||
$mysqli = $link;
|
||||
|
||||
// Make sure that client, connection and result charsets are all the
|
||||
// same. Not sure whether this is strictly necessary.
|
||||
|
||||
@@ -8,8 +8,6 @@ require_once 'skipifconnectfailure.inc';
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
require_once 'connect.inc';
|
||||
|
||||
// Note: no SQL type tests, internally the same function gets used as for mysqli_fetch_array() which does a lot of SQL type test
|
||||
|
||||
require 'table.inc';
|
||||
|
||||
@@ -8,14 +8,8 @@ require_once 'skipifconnectfailure.inc';
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
require_once 'connect.inc';
|
||||
|
||||
if (!$mysqli = my_mysqli_connect($host, $user, $passwd, $db, $port, $socket)) {
|
||||
printf("[001] Cannot connect to the server using host=%s, user=%s, passwd=***, dbname=%s, port=%s, socket=%s\n",
|
||||
$host, $user, $db, $port, $socket);
|
||||
}
|
||||
|
||||
require 'table.inc';
|
||||
$mysqli = $link;
|
||||
if (!$res = mysqli_query($link, "SELECT id, label FROM test ORDER BY id LIMIT 1")) {
|
||||
printf("[003] [%d] %s\n", mysqli_errno($link), mysqli_error($link));
|
||||
}
|
||||
|
||||
@@ -8,12 +8,8 @@ require_once 'skipifconnectfailure.inc';
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
require_once 'connect.inc';
|
||||
|
||||
if (!$mysqli = new my_mysqli($host, $user, $passwd, $db, $port, $socket))
|
||||
printf("[001] Cannot connect\n");
|
||||
|
||||
require 'table.inc';
|
||||
$mysqli = $link;
|
||||
if (!$res = $mysqli->query("SELECT id, label FROM test ORDER BY id LIMIT 1")) {
|
||||
printf("[002] [%d] %s\n", $mysqli->errno, $mysqli->error);
|
||||
}
|
||||
|
||||
@@ -8,8 +8,6 @@ require_once 'skipifconnectfailure.inc';
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
include_once 'connect.inc';
|
||||
|
||||
require 'table.inc';
|
||||
if (!$res = mysqli_query($link, "SELECT id AS ID, label FROM test AS TEST ORDER BY id LIMIT 5")) {
|
||||
printf("[003] [%d] %s\n", mysqli_errno($link), mysqli_error($link));
|
||||
|
||||
@@ -8,11 +8,6 @@ require_once 'skipifconnectfailure.inc';
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
require_once 'connect.inc';
|
||||
|
||||
$tmp = NULL;
|
||||
$link = NULL;
|
||||
|
||||
require 'table.inc';
|
||||
if (!$res = mysqli_query($link, "SELECT id AS ID, label FROM test AS TEST ORDER BY id LIMIT 5")) {
|
||||
printf("[001] [%d] %s\n", mysqli_errno($link), mysqli_error($link));
|
||||
|
||||
@@ -8,8 +8,6 @@ require_once 'skipifconnectfailure.inc';
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
require_once 'connect.inc';
|
||||
|
||||
$mysqli = new mysqli();
|
||||
try {
|
||||
new mysqli_result($mysqli);
|
||||
@@ -18,9 +16,7 @@ require_once 'skipifconnectfailure.inc';
|
||||
}
|
||||
|
||||
require 'table.inc';
|
||||
if (!$mysqli = new my_mysqli($host, $user, $passwd, $db, $port, $socket))
|
||||
printf("[002] Cannot connect to the server using host=%s, user=%s, passwd=***, dbname=%s, port=%s, socket=%s\n",
|
||||
$host, $user, $db, $port, $socket);
|
||||
$mysqli = $link;
|
||||
|
||||
if (!$res = $mysqli->query("SELECT id AS ID, label FROM test AS TEST ORDER BY id LIMIT 5")) {
|
||||
printf("[003] [%d] %s\n", $mysqli->errno, $mysqli->error);
|
||||
|
||||
@@ -8,8 +8,6 @@ require_once 'skipifconnectfailure.inc';
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
require_once 'connect.inc';
|
||||
|
||||
require 'table.inc';
|
||||
if (!$res = mysqli_query($link, "SELECT id, label, id AS _id FROM test ORDER BY id LIMIT 1")) {
|
||||
printf("[003] [%d] %s\n", mysqli_errno($link), mysqli_error($link));
|
||||
|
||||
@@ -8,8 +8,6 @@ require_once 'skipifconnectfailure.inc';
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
require_once 'connect.inc';
|
||||
|
||||
require 'table.inc';
|
||||
|
||||
var_dump(mysqli_field_count($link));
|
||||
|
||||
@@ -54,8 +54,6 @@ require_once 'skipifconnectfailure.inc';
|
||||
return $ret;
|
||||
}
|
||||
|
||||
require_once 'connect.inc';
|
||||
|
||||
require 'table.inc';
|
||||
|
||||
// Make sure that client, connection and result charsets are all the
|
||||
|
||||
@@ -8,8 +8,6 @@ require_once 'skipifconnectfailure.inc';
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
require_once 'connect.inc';
|
||||
|
||||
require 'table.inc';
|
||||
if (!$res = mysqli_query($link, "SELECT id FROM test ORDER BY id LIMIT 1", MYSQLI_USE_RESULT)) {
|
||||
printf("[003] [%d] %s\n", mysqli_errno($link), mysqli_error($link));
|
||||
|
||||
@@ -8,8 +8,6 @@ require_once 'skipifconnectfailure.inc';
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
require_once 'connect.inc';
|
||||
|
||||
require 'table.inc';
|
||||
if (!$res = mysqli_query($link, "SELECT id FROM test ORDER BY id LIMIT 1")) {
|
||||
printf("[003] [%d] %s\n", mysqli_errno($link), mysqli_error($link));
|
||||
|
||||
@@ -9,8 +9,11 @@ require_once 'skipifconnectfailure.inc';
|
||||
--FILE--
|
||||
<?php
|
||||
require_once 'connect.inc';
|
||||
|
||||
require 'table.inc';
|
||||
if (!$link = my_mysqli_connect($host, $user, $passwd, $db, $port, $socket)) {
|
||||
printf("Cannot connect to the server using host=%s, user=%s, passwd=***, dbname=%s, port=%s, socket=%s\n",
|
||||
$host, $user, $db, $port, $socket);
|
||||
exit(1);
|
||||
}
|
||||
|
||||
if (!$res = mysqli_query($link, 'SELECT version() AS server_version'))
|
||||
printf("[004] [%d] %s\n", mysqli_errno($link), mysqli_error($link));
|
||||
@@ -95,10 +98,6 @@ require_once 'skipifconnectfailure.inc';
|
||||
|
||||
print "done!";
|
||||
?>
|
||||
--CLEAN--
|
||||
<?php
|
||||
require_once 'clean_table.inc';
|
||||
?>
|
||||
--EXPECT--
|
||||
mysqli object is already closed
|
||||
done!
|
||||
|
||||
@@ -14,7 +14,12 @@ if (!function_exists('mysqli_get_connection_stats')) {
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
require 'table.inc';
|
||||
require_once 'connect.inc';
|
||||
if (!$link = my_mysqli_connect($host, $user, $passwd, $db, $port, $socket)) {
|
||||
printf("Cannot connect to the server using host=%s, user=%s, passwd=***, dbname=%s, port=%s, socket=%s\n",
|
||||
$host, $user, $db, $port, $socket);
|
||||
exit(1);
|
||||
}
|
||||
|
||||
if (!is_array($info = mysqli_get_connection_stats($link)) || empty($info))
|
||||
printf("[003] Expecting array/any_non_empty, got %s/%s\n", gettype($info), $info);
|
||||
@@ -55,7 +60,11 @@ if (!function_exists('mysqli_get_connection_stats')) {
|
||||
}
|
||||
|
||||
mysqli_close($link);
|
||||
require 'table.inc';
|
||||
if (!$link = my_mysqli_connect($host, $user, $passwd, $db, $port, $socket)) {
|
||||
printf("Cannot connect to the server using host=%s, user=%s, passwd=***, dbname=%s, port=%s, socket=%s\n",
|
||||
$host, $user, $db, $port, $socket);
|
||||
exit(1);
|
||||
}
|
||||
|
||||
if (!is_array($info = mysqli_get_connection_stats($link)) || empty($info))
|
||||
printf("[008] Expecting array/any_non_empty, got %s/%s\n", gettype($info), $info);
|
||||
@@ -72,9 +81,5 @@ if (!function_exists('mysqli_get_connection_stats')) {
|
||||
|
||||
print "done!";
|
||||
?>
|
||||
--CLEAN--
|
||||
<?php
|
||||
require_once 'clean_table.inc';
|
||||
?>
|
||||
--EXPECT--
|
||||
done!
|
||||
|
||||
@@ -9,8 +9,12 @@ require_once 'skipifconnectfailure.inc';
|
||||
--FILE--
|
||||
<?php
|
||||
require_once 'connect.inc';
|
||||
if (!$link = my_mysqli_connect($host, $user, $passwd, $db, $port, $socket)) {
|
||||
printf("Cannot connect to the server using host=%s, user=%s, passwd=***, dbname=%s, port=%s, socket=%s\n",
|
||||
$host, $user, $db, $port, $socket);
|
||||
exit(1);
|
||||
}
|
||||
|
||||
require 'table.inc';
|
||||
if (!is_string($info = mysqli_get_host_info($link)) || ('' === $info))
|
||||
printf("[003] Expecting string/any_non_empty, got %s/%s\n", gettype($info), $info);
|
||||
|
||||
@@ -21,9 +25,5 @@ require_once 'skipifconnectfailure.inc';
|
||||
}
|
||||
print "done!";
|
||||
?>
|
||||
--CLEAN--
|
||||
<?php
|
||||
require_once 'clean_table.inc';
|
||||
?>
|
||||
--EXPECT--
|
||||
done!
|
||||
|
||||
@@ -9,8 +9,12 @@ require_once 'skipifconnectfailure.inc';
|
||||
--FILE--
|
||||
<?php
|
||||
require_once 'connect.inc';
|
||||
if (!$link = my_mysqli_connect($host, $user, $passwd, $db, $port, $socket)) {
|
||||
printf("Cannot connect to the server using host=%s, user=%s, passwd=***, dbname=%s, port=%s, socket=%s\n",
|
||||
$host, $user, $db, $port, $socket);
|
||||
exit(1);
|
||||
}
|
||||
|
||||
require 'table.inc';
|
||||
if (!is_int($info = mysqli_get_proto_info($link)) || ($info < 1))
|
||||
printf("[003] Expecting int/any_non_empty, got %s/%s\n", gettype($info), $info);
|
||||
|
||||
|
||||
@@ -9,16 +9,16 @@ require_once 'skipifconnectfailure.inc';
|
||||
--FILE--
|
||||
<?php
|
||||
require_once 'connect.inc';
|
||||
if (!$link = my_mysqli_connect($host, $user, $passwd, $db, $port, $socket)) {
|
||||
printf("Cannot connect to the server using host=%s, user=%s, passwd=***, dbname=%s, port=%s, socket=%s\n",
|
||||
$host, $user, $db, $port, $socket);
|
||||
exit(1);
|
||||
}
|
||||
|
||||
require 'table.inc';
|
||||
if (!is_string($info = mysqli_get_server_info($link)) || ('' === $info))
|
||||
printf("[003] Expecting string/any_non_empty, got %s/%s\n", gettype($info), $info);
|
||||
|
||||
print "done!";
|
||||
?>
|
||||
--CLEAN--
|
||||
<?php
|
||||
require_once 'clean_table.inc';
|
||||
?>
|
||||
--EXPECT--
|
||||
done!
|
||||
|
||||
@@ -9,8 +9,12 @@ require_once 'skipifconnectfailure.inc';
|
||||
--FILE--
|
||||
<?php
|
||||
require_once 'connect.inc';
|
||||
if (!$link = my_mysqli_connect($host, $user, $passwd, $db, $port, $socket)) {
|
||||
printf("Cannot connect to the server using host=%s, user=%s, passwd=***, dbname=%s, port=%s, socket=%s\n",
|
||||
$host, $user, $db, $port, $socket);
|
||||
exit(1);
|
||||
}
|
||||
|
||||
require 'table.inc';
|
||||
/* 5.1.5 -> 50105 -- major_version*10000 + minor_version *100 + sub_version */
|
||||
/* < 30000 = pre 3.2.3, very unlikely! */
|
||||
if (!is_int($info = mysqli_get_server_version($link)) || ($info < (3 * 10000)))
|
||||
|
||||
@@ -10,8 +10,6 @@ require_once 'skipifconnectfailure.inc';
|
||||
mysqli.allow_local_infile=1
|
||||
--FILE--
|
||||
<?php
|
||||
require_once 'connect.inc';
|
||||
|
||||
require 'table.inc';
|
||||
if (!$res = mysqli_query($link, "INSERT INTO test(id, label) VALUES (100, 'a')"))
|
||||
printf("[003] [%d] %s\n", mysqli_errno($link), mysqli_error($link));
|
||||
|
||||
@@ -8,8 +8,6 @@ require_once 'skipifconnectfailure.inc';
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
require_once 'connect.inc';
|
||||
|
||||
require 'table.inc';
|
||||
|
||||
if (0 !== ($tmp = mysqli_insert_id($link)))
|
||||
|
||||
@@ -8,8 +8,6 @@ require_once 'skipifconnectfailure.inc';
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
require_once 'connect.inc';
|
||||
|
||||
require 'table.inc';
|
||||
|
||||
try {
|
||||
|
||||
@@ -8,8 +8,6 @@ require_once 'skipifconnectfailure.inc';
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
require_once 'connect.inc';
|
||||
|
||||
require 'table.inc';
|
||||
|
||||
print "[004]\n";
|
||||
|
||||
@@ -8,8 +8,6 @@ require_once 'skipifconnectfailure.inc';
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
require_once 'connect.inc';
|
||||
|
||||
require 'table.inc';
|
||||
|
||||
if (false !== ($tmp = mysqli_multi_query($link, "")))
|
||||
|
||||
@@ -8,8 +8,6 @@ require_once 'skipifconnectfailure.inc';
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
require_once 'connect.inc';
|
||||
|
||||
require 'table.inc';
|
||||
|
||||
if (false !== ($tmp = mysqli_next_result($link)))
|
||||
|
||||
@@ -8,8 +8,6 @@ require_once 'skipifconnectfailure.inc';
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
require_once 'connect.inc';
|
||||
|
||||
require 'table.inc';
|
||||
|
||||
function func_test_mysqli_num_fields($link, $query, $expected, $offset, $test_free = false) {
|
||||
|
||||
@@ -8,8 +8,6 @@ require_once 'skipifconnectfailure.inc';
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
require_once 'connect.inc';
|
||||
|
||||
require 'table.inc';
|
||||
|
||||
function func_test_mysqli_num_rows($link, $query, $expected, $offset, $test_free = false) {
|
||||
|
||||
@@ -9,8 +9,11 @@ require_once 'skipifconnectfailure.inc';
|
||||
--FILE--
|
||||
<?php
|
||||
require_once 'connect.inc';
|
||||
|
||||
require 'table.inc';
|
||||
if (!$link = my_mysqli_connect($host, $user, $passwd, $db, $port, $socket)) {
|
||||
printf("Cannot connect to the server using host=%s, user=%s, passwd=***, dbname=%s, port=%s, socket=%s\n",
|
||||
$host, $user, $db, $port, $socket);
|
||||
exit(1);
|
||||
}
|
||||
|
||||
var_dump(mysqli_ping($link));
|
||||
|
||||
|
||||
@@ -8,8 +8,6 @@ require_once 'skipifconnectfailure.inc';
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
require_once 'connect.inc';
|
||||
|
||||
require 'table.inc';
|
||||
|
||||
if (false !== ($tmp = @mysqli_prepare($link, false)))
|
||||
|
||||
@@ -8,8 +8,6 @@ require_once 'skipifconnectfailure.inc';
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
require_once 'connect.inc';
|
||||
|
||||
require 'table.inc';
|
||||
|
||||
try {
|
||||
|
||||
@@ -8,11 +8,6 @@ require_once 'skipifconnectfailure.inc';
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
require_once 'connect.inc';
|
||||
|
||||
$tmp = NULL;
|
||||
$link = NULL;
|
||||
|
||||
require 'table.inc';
|
||||
|
||||
echo "--- Testing default ---\n";
|
||||
|
||||
@@ -8,8 +8,6 @@ require_once 'skipifconnectfailure.inc';
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
require_once 'connect.inc';
|
||||
|
||||
require 'table.inc';
|
||||
|
||||
if ('\\\\' !== ($tmp = mysqli_real_escape_string($link, '\\')))
|
||||
|
||||
@@ -6,7 +6,6 @@ mysqli
|
||||
<?php
|
||||
|
||||
require_once 'skipifconnectfailure.inc';
|
||||
require_once 'connect.inc';
|
||||
|
||||
if (!$link = mysqli_connect($host, $user, $passwd, $db, $port, $socket)) {
|
||||
die(sprintf("skip Cannot connect to MySQL, [%d] %s\n",
|
||||
|
||||
@@ -6,7 +6,6 @@ mysqli
|
||||
<?php
|
||||
|
||||
require_once 'skipifconnectfailure.inc';
|
||||
require_once 'connect.inc';
|
||||
|
||||
if (!$link = mysqli_connect($host, $user, $passwd, $db, $port, $socket)) {
|
||||
die(sprintf("skip Cannot connect to MySQL, [%d] %s\n",
|
||||
|
||||
@@ -6,7 +6,6 @@ mysqli
|
||||
<?php
|
||||
|
||||
require_once 'skipifconnectfailure.inc';
|
||||
require_once 'connect.inc';
|
||||
|
||||
if (!$link = mysqli_connect($host, $user, $passwd, $db, $port, $socket)) {
|
||||
die(sprintf("skip Cannot connect to MySQL, [%d] %s\n",
|
||||
|
||||
@@ -6,7 +6,6 @@ mysqli
|
||||
<?php
|
||||
|
||||
require_once 'skipifconnectfailure.inc';
|
||||
require_once 'connect.inc';
|
||||
|
||||
if (!$link = mysqli_connect($host, $user, $passwd, $db, $port, $socket)) {
|
||||
die(sprintf("skip Cannot connect to MySQL, [%d] %s\n",
|
||||
|
||||
@@ -5,7 +5,6 @@ mysqli
|
||||
--SKIPIF--
|
||||
<?php
|
||||
require_once 'skipifconnectfailure.inc';
|
||||
require_once 'connect.inc';
|
||||
|
||||
if (!$link = mysqli_connect($host, $user, $passwd, $db, $port, $socket)) {
|
||||
die(sprintf("skip Cannot connect to MySQL, [%d] %s\n",
|
||||
|
||||
@@ -8,7 +8,6 @@ require_once 'skipifconnectfailure.inc';
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
require_once 'connect.inc';
|
||||
require_once 'table.inc';
|
||||
|
||||
if (!mysqli_query($link, 'SET @@sql_mode="NO_BACKSLASH_ESCAPES"'))
|
||||
|
||||
@@ -5,7 +5,6 @@ mysqli
|
||||
--SKIPIF--
|
||||
<?php
|
||||
require_once 'skipifconnectfailure.inc';
|
||||
require_once 'connect.inc';
|
||||
|
||||
if (!$link = mysqli_connect($host, $user, $passwd, $db, $port, $socket)) {
|
||||
die(sprintf("skip Cannot connect to MySQL, [%d] %s\n",
|
||||
@@ -17,8 +16,6 @@ mysqli_close($link);
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
require_once 'connect.inc';
|
||||
require_once 'table.inc';
|
||||
|
||||
var_dump(mysqli_set_charset($link, "sjis"));
|
||||
|
||||
@@ -9,8 +9,11 @@ require_once 'skipifconnectfailure.inc';
|
||||
--FILE--
|
||||
<?php
|
||||
require_once 'connect.inc';
|
||||
|
||||
require 'table.inc';
|
||||
if (!$link = my_mysqli_connect($host, $user, $passwd, $db, $port, $socket)) {
|
||||
printf("Cannot connect to the server using host=%s, user=%s, passwd=***, dbname=%s, port=%s, socket=%s\n",
|
||||
$host, $user, $db, $port, $socket);
|
||||
exit(1);
|
||||
}
|
||||
|
||||
if ('фу\\\\бар' !== ($tmp = mysqli_real_escape_string($link, 'фу\\бар')))
|
||||
printf("[004] Expecting фу\\\\бар, got %s\n", $tmp);
|
||||
@@ -70,10 +73,6 @@ require_once 'skipifconnectfailure.inc';
|
||||
|
||||
print "done!";
|
||||
?>
|
||||
--CLEAN--
|
||||
<?php
|
||||
require_once 'clean_table.inc';
|
||||
?>
|
||||
--EXPECT--
|
||||
mysqli object is already closed
|
||||
done!
|
||||
|
||||
@@ -8,8 +8,6 @@ require_once 'skipifconnectfailure.inc';
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
require_once 'connect.inc';
|
||||
|
||||
require 'table.inc';
|
||||
|
||||
if (false !== ($tmp = mysqli_real_query($link, 'THIS IS NOT SQL')))
|
||||
|
||||
@@ -33,7 +33,12 @@ if (mysqli_get_server_version($link) >= 50600)
|
||||
if (true !== ($tmp = mysqli_report(MYSQLI_REPORT_OFF)))
|
||||
printf("[008] Expecting boolean/true, got %s/%s\n", gettype($tmp), $tmp);
|
||||
|
||||
require 'table.inc';
|
||||
require_once 'connect.inc';
|
||||
if (!$link = my_mysqli_connect($host, $user, $passwd, $db, $port, $socket)) {
|
||||
printf("Cannot connect to the server using host=%s, user=%s, passwd=***, dbname=%s, port=%s, socket=%s\n",
|
||||
$host, $user, $db, $port, $socket);
|
||||
exit(1);
|
||||
}
|
||||
|
||||
/*
|
||||
Internal macro MYSQL_REPORT_ERROR
|
||||
@@ -99,10 +104,6 @@ if (mysqli_get_server_version($link) >= 50600)
|
||||
|
||||
print "done!";
|
||||
?>
|
||||
--CLEAN--
|
||||
<?php
|
||||
require_once 'clean_table.inc';
|
||||
?>
|
||||
--EXPECTF--
|
||||
Warning: mysqli_multi_query(): (%d/%d): You have an error in your SQL syntax; check the manual that corresponds to your %s server version for the right syntax to use near 'BAR; FOO' at line 1 in %s on line %d
|
||||
|
||||
|
||||
@@ -8,8 +8,12 @@ require_once 'skipifconnectfailure.inc';
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
require 'connect.inc';
|
||||
require 'table.inc';
|
||||
require_once 'connect.inc';
|
||||
if (!$link = my_mysqli_connect($host, $user, $passwd, $db, $port, $socket)) {
|
||||
printf("Cannot connect to the server using host=%s, user=%s, passwd=***, dbname=%s, port=%s, socket=%s\n",
|
||||
$host, $user, $db, $port, $socket);
|
||||
exit(1);
|
||||
}
|
||||
|
||||
$valid = array(MYSQLI_STORE_RESULT, MYSQLI_USE_RESULT);
|
||||
$invalidModes = [-1, 152];
|
||||
@@ -21,10 +25,6 @@ require_once 'skipifconnectfailure.inc';
|
||||
}
|
||||
}
|
||||
?>
|
||||
--CLEAN--
|
||||
<?php
|
||||
require_once 'clean_table.inc';
|
||||
?>
|
||||
--EXPECT--
|
||||
mysqli_result::__construct(): Argument #2 ($result_mode) must be either MYSQLI_STORE_RESULT or MYSQLI_USE_RESULT
|
||||
mysqli_result::__construct(): Argument #2 ($result_mode) must be either MYSQLI_STORE_RESULT or MYSQLI_USE_RESULT
|
||||
|
||||
@@ -8,8 +8,6 @@ require_once 'skipifconnectfailure.inc';
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
require_once 'connect.inc';
|
||||
|
||||
require 'table.inc';
|
||||
|
||||
var_dump(mysqli_sqlstate($link));
|
||||
|
||||
@@ -9,8 +9,11 @@ require_once 'skipifconnectfailure.inc';
|
||||
--FILE--
|
||||
<?php
|
||||
require_once 'connect.inc';
|
||||
|
||||
require 'table.inc';
|
||||
if (!$link = my_mysqli_connect($host, $user, $passwd, $db, $port, $socket)) {
|
||||
printf("Cannot connect to the server using host=%s, user=%s, passwd=***, dbname=%s, port=%s, socket=%s\n",
|
||||
$host, $user, $db, $port, $socket);
|
||||
exit(1);
|
||||
}
|
||||
|
||||
if ((!is_string($tmp = mysqli_stat($link))) || ('' === $tmp))
|
||||
printf("[004] Expecting non empty string, got %s/'%s', [%d] %s\n",
|
||||
|
||||
@@ -8,8 +8,6 @@ require_once 'skipifconnectfailure.inc';
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
require_once 'connect.inc';
|
||||
|
||||
require 'table.inc';
|
||||
|
||||
$valid_attr = array(
|
||||
|
||||
@@ -8,8 +8,6 @@ require_once 'skipifconnectfailure.inc';
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
require_once 'connect.inc';
|
||||
|
||||
require 'table.inc';
|
||||
|
||||
$valid_attr = array(MYSQLI_STMT_ATTR_UPDATE_MAX_LENGTH);
|
||||
|
||||
@@ -9,6 +9,11 @@ require_once 'skipifconnectfailure.inc';
|
||||
--FILE--
|
||||
<?php
|
||||
require_once 'connect.inc';
|
||||
if (!$link = my_mysqli_connect($host, $user, $passwd, $db, $port, $socket)) {
|
||||
printf("Cannot connect to the server using host=%s, user=%s, passwd=***, dbname=%s, port=%s, socket=%s\n",
|
||||
$host, $user, $db, $port, $socket);
|
||||
exit(1);
|
||||
}
|
||||
|
||||
// Note: No SQL tests here! We can expand one of the *fetch()
|
||||
// tests to a generic SQL test, if we ever need that.
|
||||
@@ -16,11 +21,6 @@ require_once 'skipifconnectfailure.inc';
|
||||
// fetch tests, because the fetch tests would have to call prepare/execute etc.
|
||||
// anyway.
|
||||
|
||||
$tmp = NULL;
|
||||
$link = NULL;
|
||||
|
||||
require 'table.inc';
|
||||
|
||||
$cleanupIds = range(1000, 3007);
|
||||
$model = 50;
|
||||
|
||||
@@ -42,9 +42,5 @@ require_once 'skipifconnectfailure.inc';
|
||||
mysqli_close($link);
|
||||
print "done!";
|
||||
?>
|
||||
--CLEAN--
|
||||
<?php
|
||||
require_once 'clean_table.inc';
|
||||
?>
|
||||
--EXPECT--
|
||||
done!
|
||||
|
||||
@@ -17,8 +17,6 @@ require_once 'skipifconnectfailure.inc';
|
||||
in this file and we test mysqli_stmt_bind_result() in the other
|
||||
test -- therefore the "duplicate" makes some sense to me.
|
||||
*/
|
||||
require_once 'connect.inc';
|
||||
|
||||
require 'table.inc';
|
||||
|
||||
$stmt = mysqli_stmt_init($link);
|
||||
|
||||
@@ -8,7 +8,12 @@ require_once 'skipifconnectfailure.inc';
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
require 'table.inc';
|
||||
require_once 'connect.inc';
|
||||
if (!$link = my_mysqli_connect($host, $user, $passwd, $db, $port, $socket)) {
|
||||
printf("Cannot connect to the server using host=%s, user=%s, passwd=***, dbname=%s, port=%s, socket=%s\n",
|
||||
$host, $user, $db, $port, $socket);
|
||||
exit(1);
|
||||
}
|
||||
$link->set_charset('latin1');
|
||||
|
||||
class foo {
|
||||
@@ -62,10 +67,6 @@ require_once 'skipifconnectfailure.inc';
|
||||
echo "$one - $two\n\n";
|
||||
echo "done!";
|
||||
?>
|
||||
--CLEAN--
|
||||
<?php
|
||||
require_once 'clean_table.inc';
|
||||
?>
|
||||
--EXPECTF--
|
||||
Test 1:
|
||||
object(foo)#%d (1) {
|
||||
|
||||
@@ -8,7 +8,6 @@ require_once 'skipifconnectfailure.inc';
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
require_once 'connect.inc';
|
||||
require 'table.inc';
|
||||
|
||||
$stmt = mysqli_stmt_init($link);
|
||||
|
||||
@@ -8,8 +8,6 @@ require_once 'skipifconnectfailure.inc';
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
require_once 'connect.inc';
|
||||
|
||||
require 'table.inc';
|
||||
|
||||
if (!$stmt = mysqli_stmt_init($link))
|
||||
|
||||
@@ -8,8 +8,6 @@ require_once 'skipifconnectfailure.inc';
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
require_once 'connect.inc';
|
||||
|
||||
require 'table.inc';
|
||||
|
||||
if (!$stmt = mysqli_stmt_init($link))
|
||||
|
||||
@@ -8,8 +8,6 @@ require_once 'skipifconnectfailure.inc';
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
require_once 'connect.inc';
|
||||
|
||||
require 'table.inc';
|
||||
|
||||
if (!$stmt = mysqli_stmt_init($link))
|
||||
|
||||
@@ -8,8 +8,6 @@ require_once 'skipifconnectfailure.inc';
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
require_once 'connect.inc';
|
||||
|
||||
require 'table.inc';
|
||||
|
||||
if (!$stmt = mysqli_stmt_init($link))
|
||||
|
||||
@@ -8,8 +8,6 @@ require_once 'skipifconnectfailure.inc';
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
require_once 'connect.inc';
|
||||
|
||||
require 'table.inc';
|
||||
|
||||
mysqli_report(MYSQLI_REPORT_ERROR | MYSQLI_REPORT_STRICT);
|
||||
|
||||
@@ -13,8 +13,6 @@ require_once 'skipifconnectfailure.inc';
|
||||
mysqli_stmt_bind_result.phpt already. Restrict
|
||||
this test case to the basics.
|
||||
*/
|
||||
require_once 'connect.inc';
|
||||
|
||||
require 'table.inc';
|
||||
|
||||
if (!$stmt = mysqli_stmt_init($link))
|
||||
|
||||
@@ -8,8 +8,6 @@ require_once 'skipifconnectfailure.inc';
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
require_once 'connect.inc';
|
||||
|
||||
require 'table.inc';
|
||||
|
||||
$stmt = mysqli_stmt_init($link);
|
||||
|
||||
@@ -13,8 +13,6 @@ require_once 'skipifconnectfailure.inc';
|
||||
mysqli_stmt_bind_result.phpt already. Restrict
|
||||
this test case to the basics.
|
||||
*/
|
||||
require_once 'connect.inc';
|
||||
|
||||
require 'table.inc';
|
||||
|
||||
if (!$stmt = mysqli_stmt_init($link))
|
||||
|
||||
@@ -16,8 +16,6 @@ if (!function_exists('mysqli_stmt_get_result'))
|
||||
mysqli_stmt_bind_result.phpt already. Restrict
|
||||
this test case to the basics.
|
||||
*/
|
||||
require_once 'connect.inc';
|
||||
|
||||
require 'table.inc';
|
||||
|
||||
if (!$stmt = mysqli_stmt_init($link))
|
||||
|
||||
@@ -15,8 +15,6 @@ if (!function_exists('mysqli_stmt_get_result'))
|
||||
mysqli_stmt_bind_result.phpt already. Restrict
|
||||
this test case to the basics.
|
||||
*/
|
||||
require_once 'connect.inc';
|
||||
|
||||
require 'table.inc';
|
||||
|
||||
if (!$stmt = mysqli_stmt_init($link))
|
||||
|
||||
@@ -14,8 +14,11 @@ require_once 'skipifconnectfailure.inc';
|
||||
this test case to the basics.
|
||||
*/
|
||||
require_once 'connect.inc';
|
||||
|
||||
require 'table.inc';
|
||||
if (!$link = my_mysqli_connect($host, $user, $passwd, $db, $port, $socket)) {
|
||||
printf("Cannot connect to the server using host=%s, user=%s, passwd=***, dbname=%s, port=%s, socket=%s\n",
|
||||
$host, $user, $db, $port, $socket);
|
||||
exit(1);
|
||||
}
|
||||
|
||||
if (!is_object($stmt = mysqli_stmt_init($link)))
|
||||
printf("[003] [%d] %s\n", mysqli_errno($link), mysqli_error($link));
|
||||
@@ -39,10 +42,6 @@ require_once 'skipifconnectfailure.inc';
|
||||
|
||||
print "done!";
|
||||
?>
|
||||
--CLEAN--
|
||||
<?php
|
||||
require_once 'clean_table.inc';
|
||||
?>
|
||||
--EXPECT--
|
||||
mysqli_stmt object is not fully initialized
|
||||
mysqli object is already closed
|
||||
|
||||
@@ -8,8 +8,6 @@ require_once 'skipifconnectfailure.inc';
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
require_once 'connect.inc';
|
||||
|
||||
require 'table.inc';
|
||||
|
||||
$stmt = mysqli_stmt_init($link);
|
||||
|
||||
@@ -8,8 +8,6 @@ require_once 'skipifconnectfailure.inc';
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
require_once 'connect.inc';
|
||||
|
||||
require 'table.inc';
|
||||
|
||||
if (!$stmt = mysqli_stmt_init($link))
|
||||
|
||||
@@ -8,8 +8,6 @@ require_once 'skipifconnectfailure.inc';
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
require_once 'connect.inc';
|
||||
|
||||
require 'table.inc';
|
||||
|
||||
if (!$stmt = mysqli_stmt_init($link))
|
||||
|
||||
@@ -8,8 +8,6 @@ require_once 'skipifconnectfailure.inc';
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
require_once 'connect.inc';
|
||||
|
||||
// Note: No SQL tests here! We can expand one of the *fetch()
|
||||
// tests to a generic SQL test, if we ever need that.
|
||||
// We would duplicate the SQL test cases if we have it here and in one of the
|
||||
|
||||
@@ -8,8 +8,6 @@ require_once 'skipifconnectfailure.inc';
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
require_once 'connect.inc';
|
||||
|
||||
// Note: No SQL tests here! We can expand one of the *fetch()
|
||||
// tests to a generic SQL test, if we ever need that.
|
||||
// We would duplicate the SQL test cases if we have it here and in one of the
|
||||
|
||||
@@ -8,8 +8,6 @@ require_once 'skipifconnectfailure.inc';
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
require_once 'connect.inc';
|
||||
|
||||
require 'table.inc';
|
||||
|
||||
if (!$stmt = mysqli_stmt_init($link))
|
||||
|
||||
@@ -8,8 +8,6 @@ require_once 'skipifconnectfailure.inc';
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
require_once 'connect.inc';
|
||||
|
||||
require 'table.inc';
|
||||
|
||||
if (!$stmt = mysqli_stmt_init($link))
|
||||
|
||||
@@ -8,8 +8,6 @@ require_once 'skipifconnectfailure.inc';
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
require_once 'connect.inc';
|
||||
|
||||
require 'table.inc';
|
||||
|
||||
if (!$stmt = mysqli_stmt_init($link))
|
||||
|
||||
@@ -8,8 +8,6 @@ require_once 'skipifconnectfailure.inc';
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
require_once 'connect.inc';
|
||||
|
||||
require 'table.inc';
|
||||
|
||||
if (!$stmt = mysqli_stmt_init($link))
|
||||
|
||||
@@ -8,8 +8,6 @@ require_once 'skipifconnectfailure.inc';
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
require_once 'connect.inc';
|
||||
|
||||
require 'table.inc';
|
||||
|
||||
if (!$res = mysqli_real_query($link, "SELECT id, label FROM test ORDER BY id"))
|
||||
|
||||
@@ -11,12 +11,6 @@ if (!defined('MYSQLI_STORE_RESULT_COPY_DATA')) {
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
require_once 'connect.inc';
|
||||
|
||||
$tmp = NULL;
|
||||
$link = NULL;
|
||||
|
||||
|
||||
require 'table.inc';
|
||||
|
||||
if (!$res = mysqli_real_query($link, "SELECT id, label FROM test ORDER BY id"))
|
||||
|
||||
@@ -13,11 +13,6 @@ mysqlnd.mempool_default_size=1
|
||||
mysqlnd.fetch_data_copy=0
|
||||
--FILE--
|
||||
<?php
|
||||
require_once 'connect.inc';
|
||||
|
||||
$tmp = NULL;
|
||||
$link = NULL;
|
||||
|
||||
require 'table.inc';
|
||||
|
||||
if (!$res = mysqli_real_query($link, "SELECT id, label FROM test ORDER BY id"))
|
||||
|
||||
@@ -9,8 +9,11 @@ require_once 'skipifconnectfailure.inc';
|
||||
--FILE--
|
||||
<?php
|
||||
require_once 'connect.inc';
|
||||
|
||||
require 'table.inc';
|
||||
if (!$link = my_mysqli_connect($host, $user, $passwd, $db, $port, $socket)) {
|
||||
printf("Cannot connect to the server using host=%s, user=%s, passwd=***, dbname=%s, port=%s, socket=%s\n",
|
||||
$host, $user, $db, $port, $socket);
|
||||
exit(1);
|
||||
}
|
||||
|
||||
if (!is_int($tmp = mysqli_thread_id($link)) || (0 === $tmp))
|
||||
printf("[003] Expecting int/any but zero, got %s/%s. [%d] %s\n",
|
||||
@@ -29,10 +32,6 @@ require_once 'skipifconnectfailure.inc';
|
||||
|
||||
print "done!";
|
||||
?>
|
||||
--CLEAN--
|
||||
<?php
|
||||
require_once 'clean_table.inc';
|
||||
?>
|
||||
--EXPECT--
|
||||
mysqli object is already closed
|
||||
done!
|
||||
|
||||
@@ -8,8 +8,6 @@ require_once 'skipifconnectfailure.inc';
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
require_once 'connect.inc';
|
||||
|
||||
require 'table.inc';
|
||||
|
||||
if (!$res = mysqli_real_query($link, "SELECT id, label FROM test ORDER BY id"))
|
||||
|
||||
@@ -8,8 +8,6 @@ require_once 'skipifconnectfailure.inc';
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
require_once 'connect.inc';
|
||||
|
||||
require 'table.inc';
|
||||
|
||||
if (!$res = mysqli_query($link, "SELECT id, label FROM test"))
|
||||
|
||||
Reference in New Issue
Block a user