Fixing typo in SKIPIF and partly skipping tests if using remote MySQL because LOAD LOCAL INFILE will fail

This commit is contained in:
Ulf Wendel 2009-10-20 12:31:04 +00:00
parent 0efa2445ad
commit 57c1b63c2d
16 changed files with 23 additions and 15 deletions

View File

@ -13,6 +13,14 @@ if (!$fp = fopen('./simple.csv', 'w'))
fclose($fp);
@unlink('./simple.csv');
require_once("connect.inc");
if ($socket == "" && $host != NULL && $host != 'localhost' && $host != '.') {
/* could be a remote TCP/IP connection. LOCAL INFILE may not work */
if (gethostbyaddr($host) != gethostname()) {
die("skip LOAD DATA LOCAL INFILE will fail if connecting to remote MySQL");
}
}
?>
--INI--
safe_mode=0

View File

@ -10,7 +10,7 @@ if (!function_exists('mysqli_set_local_infile_handler'))
die("skip - function not available.");
require_once('connect.inc');
if (!$link = my_mysqli_connect($host, $user, $passwb, $db, $port, $socket))
if (!$link = my_mysqli_connect($host, $user, $passwd, $db, $port, $socket))
die("skip Cannot connect to MySQL");
if (!$res = mysqli_query($link, 'SHOW VARIABLES LIKE "local_infile"')) {

View File

@ -13,7 +13,7 @@ if (!function_exists('mysqli_set_local_infile_handler'))
if (!$TEST_EXPERIMENTAL)
die("skip - experimental (= unsupported) feature");
if (!$link = my_mysqli_connect($host, $user, $passwb, $db, $port, $socket))
if (!$link = my_mysqli_connect($host, $user, $passwd, $db, $port, $socket))
die("skip Cannot connect to MySQL");
if (!$res = mysqli_query($link, 'SHOW VARIABLES LIKE "local_infile"')) {

View File

@ -13,7 +13,7 @@ require_once('connect.inc');
if (!$TEST_EXPERIMENTAL)
die("skip - experimental (= unsupported) feature");
if (!$link = my_mysqli_connect($host, $user, $passwb, $db, $port, $socket))
if (!$link = my_mysqli_connect($host, $user, $passwd, $db, $port, $socket))
die("skip Cannot connect to MySQL");
if (!$res = mysqli_query($link, 'SHOW VARIABLES LIKE "local_infile"')) {

View File

@ -13,7 +13,7 @@ require_once('connect.inc');
if (!$TEST_EXPERIMENTAL)
die("skip - experimental (= unsupported) feature");
if (!$link = my_mysqli_connect($host, $user, $passwb, $db, $port, $socket))
if (!$link = my_mysqli_connect($host, $user, $passwd, $db, $port, $socket))
die("skip Cannot connect to MySQL");
if (!$res = mysqli_query($link, 'SHOW VARIABLES LIKE "local_infile"')) {

View File

@ -13,7 +13,7 @@ require_once('connect.inc');
if (!$TEST_EXPERIMENTAL)
die("skip - experimental (= unsupported) feature");
if (!$link = my_mysqli_connect($host, $user, $passwb, $db, $port, $socket))
if (!$link = my_mysqli_connect($host, $user, $passwd, $db, $port, $socket))
die("skip Cannot connect to MySQL");
if (!$res = mysqli_query($link, 'SHOW VARIABLES LIKE "local_infile"')) {

View File

@ -13,7 +13,7 @@ require_once('connect.inc');
if (!$TEST_EXPERIMENTAL)
die("skip - experimental (= unsupported) feature");
if (!$link = my_mysqli_connect($host, $user, $passwb, $db, $port, $socket))
if (!$link = my_mysqli_connect($host, $user, $passwd, $db, $port, $socket))
die("skip Cannot connect to MySQL");
if (!$res = mysqli_query($link, 'SHOW VARIABLES LIKE "local_infile"')) {

View File

@ -10,7 +10,7 @@ if (!function_exists('mysqli_set_local_infile_handler'))
die("skip - function not available.");
require_once('connect.inc');
if (!$link = my_mysqli_connect($host, $user, $passwb, $db, $port, $socket))
if (!$link = my_mysqli_connect($host, $user, $passwd, $db, $port, $socket))
die("skip Cannot connect to MySQL");
if (!$res = mysqli_query($link, 'SHOW VARIABLES LIKE "local_infile"')) {

View File

@ -13,7 +13,7 @@ require_once('connect.inc');
if (!$TEST_EXPERIMENTAL)
die("skip - experimental (= unsupported) feature");
if (!$link = my_mysqli_connect($host, $user, $passwb, $db, $port, $socket))
if (!$link = my_mysqli_connect($host, $user, $passwd, $db, $port, $socket))
die("skip Cannot connect to MySQL");
if (!$res = mysqli_query($link, 'SHOW VARIABLES LIKE "local_infile"')) {

View File

@ -13,7 +13,7 @@ require_once('connect.inc');
if (!$TEST_EXPERIMENTAL)
die("skip - experimental (= unsupported) feature");
if (!$link = my_mysqli_connect($host, $user, $passwb, $db, $port, $socket))
if (!$link = my_mysqli_connect($host, $user, $passwd, $db, $port, $socket))
die("skip Cannot connect to MySQL");
if (!$res = mysqli_query($link, 'SHOW VARIABLES LIKE "local_infile"')) {

View File

@ -13,7 +13,7 @@ require_once('connect.inc');
if (!$TEST_EXPERIMENTAL)
die("skip - experimental (= unsupported) feature");
if (!$link = my_mysqli_connect($host, $user, $passwb, $db, $port, $socket))
if (!$link = my_mysqli_connect($host, $user, $passwd, $db, $port, $socket))
die("skip Cannot connect to MySQL");
if (!$res = mysqli_query($link, 'SHOW VARIABLES LIKE "local_infile"')) {

View File

@ -13,7 +13,7 @@ require_once('connect.inc');
if (!$TEST_EXPERIMENTAL)
die("skip - experimental (= unsupported) feature");
if (!$link = my_mysqli_connect($host, $user, $passwb, $db, $port, $socket))
if (!$link = my_mysqli_connect($host, $user, $passwd, $db, $port, $socket))
die("skip Cannot connect to MySQL");
if (!$res = mysqli_query($link, 'SHOW VARIABLES LIKE "local_infile"')) {

View File

@ -10,7 +10,7 @@ if (!function_exists('mysqli_set_local_infile_handler'))
die("skip - function not available.");
require_once('connect.inc');
if (!$link = my_mysqli_connect($host, $user, $passwb, $db, $port, $socket))
if (!$link = my_mysqli_connect($host, $user, $passwd, $db, $port, $socket))
die("skip Cannot connect to MySQL");
if (!$res = mysqli_query($link, 'SHOW VARIABLES LIKE "local_infile"')) {

View File

@ -13,7 +13,7 @@ require_once('connect.inc');
if (!$TEST_EXPERIMENTAL)
die("skip - experimental (= unsupported) feature");
if (!$link = my_mysqli_connect($host, $user, $passwb, $db, $port, $socket))
if (!$link = my_mysqli_connect($host, $user, $passwd, $db, $port, $socket))
die("skip Cannot connect to MySQL");
if (!$res = mysqli_query($link, 'SHOW VARIABLES LIKE "local_infile"')) {

View File

@ -13,7 +13,7 @@ require_once('connect.inc');
if (!$TEST_EXPERIMENTAL)
die("skip - experimental (= unsupported) feature");
if (!$link = my_mysqli_connect($host, $user, $passwb, $db, $port, $socket))
if (!$link = my_mysqli_connect($host, $user, $passwd, $db, $port, $socket))
die("skip Cannot connect to MySQL");
if (!$res = mysqli_query($link, 'SHOW VARIABLES LIKE "local_infile"')) {

View File

@ -10,7 +10,7 @@ if (!function_exists('mysqli_set_local_infile_handler'))
die("skip - function not available.");
require_once('connect.inc');
if (!$link = my_mysqli_connect($host, $user, $passwb, $db, $port, $socket))
if (!$link = my_mysqli_connect($host, $user, $passwd, $db, $port, $socket))
die("skip Cannot connect to MySQL");
if (!$res = mysqli_query($link, 'SHOW VARIABLES LIKE "local_infile"')) {