summaryrefslogtreecommitdiff
path: root/ext/mysqli/tests
diff options
context:
space:
mode:
Diffstat (limited to 'ext/mysqli/tests')
-rw-r--r--ext/mysqli/tests/001.phpt47
-rw-r--r--ext/mysqli/tests/002.phpt62
-rw-r--r--ext/mysqli/tests/003.phpt58
-rw-r--r--ext/mysqli/tests/004.phpt37
-rw-r--r--ext/mysqli/tests/005.phpt40
-rw-r--r--ext/mysqli/tests/006.phpt53
-rw-r--r--ext/mysqli/tests/007.phpt53
-rw-r--r--ext/mysqli/tests/008.phpt53
-rw-r--r--ext/mysqli/tests/009.phpt53
-rw-r--r--ext/mysqli/tests/010.phpt58
-rw-r--r--ext/mysqli/tests/011.phpt57
-rw-r--r--ext/mysqli/tests/012.phpt58
-rw-r--r--ext/mysqli/tests/013.phpt47
-rw-r--r--ext/mysqli/tests/014.phpt70
-rw-r--r--ext/mysqli/tests/015.phpt70
-rw-r--r--ext/mysqli/tests/016.phpt27
-rw-r--r--ext/mysqli/tests/017.phpt37
-rw-r--r--ext/mysqli/tests/018.phpt27
-rw-r--r--ext/mysqli/tests/019.phpt70
-rw-r--r--ext/mysqli/tests/020.phpt66
-rw-r--r--ext/mysqli/tests/021.phpt42
-rw-r--r--ext/mysqli/tests/022.phpt46
-rw-r--r--ext/mysqli/tests/023.phpt64
-rw-r--r--ext/mysqli/tests/024.phpt65
-rw-r--r--ext/mysqli/tests/025.phpt69
-rw-r--r--ext/mysqli/tests/026.phpt48
-rw-r--r--ext/mysqli/tests/027.phpt20
-rw-r--r--ext/mysqli/tests/028.phpt19
-rw-r--r--ext/mysqli/tests/029.phpt25
-rw-r--r--ext/mysqli/tests/030.phpt25
-rw-r--r--ext/mysqli/tests/031.phpt25
-rw-r--r--ext/mysqli/tests/032.phpt25
-rw-r--r--ext/mysqli/tests/033.phpt20
-rw-r--r--ext/mysqli/tests/034.phpt20
-rw-r--r--ext/mysqli/tests/035.phpt19
-rw-r--r--ext/mysqli/tests/036.phpt45
-rw-r--r--ext/mysqli/tests/037.phpt36
-rw-r--r--ext/mysqli/tests/038.phpt33
-rw-r--r--ext/mysqli/tests/039.phpt26
-rw-r--r--ext/mysqli/tests/040.phpt33
-rw-r--r--ext/mysqli/tests/041.phpt26
-rw-r--r--ext/mysqli/tests/042.phpt61
-rw-r--r--ext/mysqli/tests/043.phpt42
-rw-r--r--ext/mysqli/tests/044.phpt21
-rw-r--r--ext/mysqli/tests/045.phpt46
-rw-r--r--ext/mysqli/tests/046.phpt33
-rw-r--r--ext/mysqli/tests/047.phpt83
-rw-r--r--ext/mysqli/tests/048.phpt62
-rw-r--r--ext/mysqli/tests/049.phpt24
-rw-r--r--ext/mysqli/tests/050.phpt21
-rw-r--r--ext/mysqli/tests/051.phpt22
-rw-r--r--ext/mysqli/tests/052.phpt22
-rw-r--r--ext/mysqli/tests/053.phpt20
-rw-r--r--ext/mysqli/tests/054.phpt20
-rw-r--r--ext/mysqli/tests/055.phpt19
-rw-r--r--ext/mysqli/tests/056.phpt21
-rw-r--r--ext/mysqli/tests/057.phpt54
-rw-r--r--ext/mysqli/tests/058.phpt57
-rw-r--r--ext/mysqli/tests/059.phpt41
-rw-r--r--ext/mysqli/tests/060.phpt59
-rw-r--r--ext/mysqli/tests/061.phpt42
-rw-r--r--ext/mysqli/tests/062.phpt25
-rw-r--r--ext/mysqli/tests/063.phpt21
-rw-r--r--ext/mysqli/tests/064.phpt21
-rw-r--r--ext/mysqli/tests/065.phpt37
-rw-r--r--ext/mysqli/tests/bug28817.phpt39
-rw-r--r--ext/mysqli/tests/bug29311.phpt48
-rw-r--r--ext/mysqli/tests/bug30967.phpt23
-rw-r--r--ext/mysqli/tests/bug31141.phpt28
-rw-r--r--ext/mysqli/tests/bug31668.phpt56
-rw-r--r--ext/mysqli/tests/bug32405.phpt38
-rw-r--r--ext/mysqli/tests/bug33090.phpt21
-rw-r--r--ext/mysqli/tests/connect.inc23
-rw-r--r--ext/mysqli/tests/skipif.inc5
-rw-r--r--ext/mysqli/tests/skipifemb.inc5
75 files changed, 0 insertions, 2934 deletions
diff --git a/ext/mysqli/tests/001.phpt b/ext/mysqli/tests/001.phpt
deleted file mode 100644
index 3f2f3c2d31..0000000000
--- a/ext/mysqli/tests/001.phpt
+++ /dev/null
@@ -1,47 +0,0 @@
---TEST--
-mysqli connect
---SKIPIF--
-<?php require_once('skipif.inc'); ?>
-<?php require_once('skipifemb.inc'); ?>
---FILE--
-<?php
- include "connect.inc";
-
- $dbname = "test";
- $test = "";
-
- /*** test mysqli_connect localhost:port ***/
- $link = mysqli_connect($host, $user, $passwd, "", 3306);
- $test .= ($link) ? "1" : "0";
- mysqli_close($link);
-
- /*** test mysqli_real_connect ***/
- $link = mysqli_init();
- $test.= (mysqli_real_connect($link, $host, $user, $passwd))
- ? "1" : "0";
- mysqli_close($link);
-
- /*** test mysqli_real_connect with db ***/
- $link = mysqli_init();
- $test .= (mysqli_real_connect($link, $host, $user, $passwd, $dbname))
- ? "1" : "0";
- mysqli_close($link);
-
- /*** test mysqli_real_connect with port ***/
- $link = mysqli_init();
- $test .= (mysqli_real_connect($link, $host, $user, $passwd, $dbname, 3306))
- ? "1":"0";
- mysqli_close($link);
-
- /*** test mysqli_real_connect compressed ***/
- $link = mysqli_init();
- $test .= (mysqli_real_connect($link, $host, $user, $passwd, $dbname, 0, NULL, MYSQLI_CLIENT_COMPRESS))
- ? "1" : "0";
- mysqli_close($link);
-
- /* todo ssl connections */
-
- var_dump($test);
-?>
---EXPECT--
-string(5) "11111"
diff --git a/ext/mysqli/tests/002.phpt b/ext/mysqli/tests/002.phpt
deleted file mode 100644
index fa4e60e185..0000000000
--- a/ext/mysqli/tests/002.phpt
+++ /dev/null
@@ -1,62 +0,0 @@
---TEST--
-mysqli bind_result 1
---SKIPIF--
-<?php require_once('skipif.inc'); ?>
---FILE--
-<?php
- include "connect.inc";
-
- /*** test mysqli_connect 127.0.0.1 ***/
- $link = mysqli_connect($host, $user, $passwd);
-
- mysqli_select_db($link, "test");
- $rc = mysqli_query($link,"DROP TABLE IF EXISTS test_fetch_null");
-
- $rc = mysqli_query($link,"CREATE TABLE test_fetch_null(col1 tinyint, col2 smallint,
- col3 int, col4 bigint,
- col5 float, col6 double,
- col7 date, col8 time,
- col9 varbinary(10),
- col10 varchar(50),
- col11 char(20))");
-
- $rc = mysqli_query($link,"INSERT INTO test_fetch_null(col1,col10, col11) VALUES(1,'foo1', 1000),(2,'foo2', 88),(3,'foo3', 389789)");
-
- $stmt = mysqli_prepare($link, "SELECT col1, col2, col3, col4, col5, col6, col7, col8, col9, col10, col11 from test_fetch_null");
- mysqli_bind_result($stmt, $c1, $c2, $c3, $c4, $c5, $c6, $c7, $c8, $c9, $c10, $c11);
- mysqli_execute($stmt);
-
- mysqli_fetch($stmt);
-
- $test = array($c1,$c2,$c3,$c4,$c5,$c6,$c7,$c8,$c9,$c10,$c11);
-
- var_dump($test);
-
- mysqli_stmt_close($stmt);
- mysqli_close($link);
-?>
---EXPECT--
-array(11) {
- [0]=>
- int(1)
- [1]=>
- NULL
- [2]=>
- NULL
- [3]=>
- NULL
- [4]=>
- NULL
- [5]=>
- NULL
- [6]=>
- NULL
- [7]=>
- NULL
- [8]=>
- NULL
- [9]=>
- string(4) "foo1"
- [10]=>
- string(4) "1000"
-}
diff --git a/ext/mysqli/tests/003.phpt b/ext/mysqli/tests/003.phpt
deleted file mode 100644
index d043dc7724..0000000000
--- a/ext/mysqli/tests/003.phpt
+++ /dev/null
@@ -1,58 +0,0 @@
---TEST--
-mysqli connect
---SKIPIF--
-<?php require_once('skipif.inc'); ?>
---FILE--
-<?php
- include "connect.inc";
-
- /*** test mysqli_connect 127.0.0.1 ***/
- $link = mysqli_connect($host, $user, $passwd);
-
- mysqli_select_db($link, "test");
-
- mysqli_query($link,"DROP TABLE IF EXISTS test_bind_result");
- mysqli_query($link,"CREATE TABLE test_bind_result(c1 date, c2 time,
- c3 timestamp(14),
- c4 year,
- c5 datetime,
- c6 timestamp(4),
- c7 timestamp(6))");
-
- mysqli_query($link,"INSERT INTO test_bind_result VALUES('2002-01-02',
- '12:49:00',
- '2002-01-02 17:46:59',
- 2010,
- '2010-07-10',
- '2020','1999-12-29')");
-
-
- $stmt = mysqli_prepare($link, "SELECT * FROM test_bind_result");
- mysqli_bind_result($stmt, $c1, $c2, $c3, $c4, $c5, $c6, $c7);
- mysqli_execute($stmt);
- mysqli_fetch($stmt);
-
- $test = array($c1,$c2,$c3,$c4,$c5,$c6,$c7);
-
- var_dump($test);
-
- mysqli_stmt_close($stmt);
- mysqli_close($link);
-?>
---EXPECT--
-array(7) {
- [0]=>
- string(10) "2002-01-02"
- [1]=>
- string(8) "12:49:00"
- [2]=>
- string(19) "2002-01-02 17:46:59"
- [3]=>
- int(2010)
- [4]=>
- string(19) "2010-07-10 00:00:00"
- [5]=>
- string(19) "0000-00-00 00:00:00"
- [6]=>
- string(19) "1999-12-29 00:00:00"
-}
diff --git a/ext/mysqli/tests/004.phpt b/ext/mysqli/tests/004.phpt
deleted file mode 100644
index c80c7214e3..0000000000
--- a/ext/mysqli/tests/004.phpt
+++ /dev/null
@@ -1,37 +0,0 @@
---TEST--
-mysqli fetch char/text
---SKIPIF--
-<?php require_once('skipif.inc'); ?>
---FILE--
-<?php
- include ("connect.inc");
-
- /*** test mysqli_connect 127.0.0.1 ***/
- $link = mysqli_connect($host, $user, $passwd);
-
- mysqli_select_db($link, "test");
-
- mysqli_query($link,"DROP TABLE IF EXISTS test_bind_fetch");
- mysqli_query($link,"CREATE TABLE test_bind_fetch(c1 char(10), c2 text)");
-
- mysqli_query($link, "INSERT INTO test_bind_fetch VALUES ('1234567890', 'this is a test')");
-
- $stmt = mysqli_prepare($link, "SELECT * FROM test_bind_fetch");
- mysqli_bind_result($stmt, $c1, $c2);
- mysqli_execute($stmt);
- mysqli_fetch($stmt);
-
- $test = array($c1,$c2);
-
- var_dump($test);
-
- mysqli_stmt_close($stmt);
- mysqli_close($link);
-?>
---EXPECT--
-array(2) {
- [0]=>
- string(10) "1234567890"
- [1]=>
- string(14) "this is a test"
-}
diff --git a/ext/mysqli/tests/005.phpt b/ext/mysqli/tests/005.phpt
deleted file mode 100644
index a9f75cfd7e..0000000000
--- a/ext/mysqli/tests/005.phpt
+++ /dev/null
@@ -1,40 +0,0 @@
---TEST--
-mysqli fetch char/text long
---SKIPIF--
-<?php require_once('skipif.inc'); ?>
---FILE--
-<?php
- include "connect.inc";
-
- /*** test mysqli_connect 127.0.0.1 ***/
- $link = mysqli_connect($host, $user, $passwd);
-
- mysqli_select_db($link, "test");
-
- mysqli_query($link,"DROP TABLE IF EXISTS test_bind_fetch");
- mysqli_query($link,"CREATE TABLE test_bind_fetch(c1 char(10), c2 text)");
-
- $a = str_repeat("A1", 32000);
-
- mysqli_query($link, "INSERT INTO test_bind_fetch VALUES ('1234567890', '$a')");
-
- $stmt = mysqli_prepare($link, "SELECT * FROM test_bind_fetch");
- mysqli_bind_result($stmt, $c1, $c2);
- mysqli_execute($stmt);
- mysqli_fetch($stmt);
-
- $test[] = $c1;
- $test[] = ($a == $c2) ? "32K String ok" : "32K String failed";
-
- var_dump($test);
-
- mysqli_stmt_close($stmt);
- mysqli_close($link);
-?>
---EXPECT--
-array(2) {
- [0]=>
- string(10) "1234567890"
- [1]=>
- string(13) "32K String ok"
-}
diff --git a/ext/mysqli/tests/006.phpt b/ext/mysqli/tests/006.phpt
deleted file mode 100644
index 4b495cc594..0000000000
--- a/ext/mysqli/tests/006.phpt
+++ /dev/null
@@ -1,53 +0,0 @@
---TEST--
-mysqli fetch long values
---SKIPIF--
-<?php require_once('skipif.inc'); ?>
---FILE--
-<?php
- include "connect.inc";
-
- /*** test mysqli_connect 127.0.0.1 ***/
- $link = mysqli_connect($host, $user, $passwd);
-
- mysqli_select_db($link, "test");
-
- mysqli_query($link,"DROP TABLE IF EXISTS test_bind_fetch");
- mysqli_query($link,"CREATE TABLE test_bind_fetch(c1 int unsigned,
- c2 int unsigned,
- c3 int,
- c4 int,
- c5 int,
- c6 int unsigned,
- c7 int)");
-
- mysqli_query($link, "INSERT INTO test_bind_fetch VALUES (-23,35999,NULL,-500,-9999999,-0,0)");
-
- $stmt = mysqli_prepare($link, "SELECT * FROM test_bind_fetch");
- mysqli_bind_result($stmt, $c1, $c2, $c3, $c4, $c5, $c6, $c7);
- mysqli_execute($stmt);
- mysqli_fetch($stmt);
-
- $test = array($c1,$c2,$c3,$c4,$c5,$c6,$c7);
-
- var_dump($test);
-
- mysqli_stmt_close($stmt);
- mysqli_close($link);
-?>
---EXPECT--
-array(7) {
- [0]=>
- int(0)
- [1]=>
- int(35999)
- [2]=>
- NULL
- [3]=>
- int(-500)
- [4]=>
- int(-9999999)
- [5]=>
- int(0)
- [6]=>
- int(0)
-}
diff --git a/ext/mysqli/tests/007.phpt b/ext/mysqli/tests/007.phpt
deleted file mode 100644
index 503863bdc2..0000000000
--- a/ext/mysqli/tests/007.phpt
+++ /dev/null
@@ -1,53 +0,0 @@
---TEST--
-mysqli fetch short values
---SKIPIF--
-<?php require_once('skipif.inc'); ?>
---FILE--
-<?php
- include "connect.inc";
-
- /*** test mysqli_connect 127.0.0.1 ***/
- $link = mysqli_connect($host, $user, $passwd);
-
- mysqli_select_db($link, "test");
-
- mysqli_query($link,"DROP TABLE IF EXISTS test_bind_fetch");
- mysqli_query($link,"CREATE TABLE test_bind_fetch(c1 smallint unsigned,
- c2 smallint unsigned,
- c3 smallint,
- c4 smallint,
- c5 smallint,
- c6 smallint unsigned,
- c7 smallint)");
-
- mysqli_query($link, "INSERT INTO test_bind_fetch VALUES (-23,35999,NULL,-500,-9999999,+30,0)");
-
- $stmt = mysqli_prepare($link, "SELECT * FROM test_bind_fetch");
- mysqli_bind_result($stmt, $c1, $c2, $c3, $c4, $c5, $c6, $c7);
- mysqli_execute($stmt);
- mysqli_fetch($stmt);
-
- $test = array($c1,$c2,$c3,$c4,$c5,$c6,$c7);
-
- var_dump($test);
-
- mysqli_stmt_close($stmt);
- mysqli_close($link);
-?>
---EXPECT--
-array(7) {
- [0]=>
- int(0)
- [1]=>
- int(35999)
- [2]=>
- NULL
- [3]=>
- int(-500)
- [4]=>
- int(-32768)
- [5]=>
- int(30)
- [6]=>
- int(0)
-}
diff --git a/ext/mysqli/tests/008.phpt b/ext/mysqli/tests/008.phpt
deleted file mode 100644
index 12311d621b..0000000000
--- a/ext/mysqli/tests/008.phpt
+++ /dev/null
@@ -1,53 +0,0 @@
---TEST--
-mysqli fetch tinyint values
---SKIPIF--
-<?php require_once('skipif.inc'); ?>
---FILE--
-<?php
- include "connect.inc";
-
- /*** test mysqli_connect 127.0.0.1 ***/
- $link = mysqli_connect($host, $user, $passwd);
-
- mysqli_select_db($link, "test");
-
- mysqli_query($link,"DROP TABLE IF EXISTS test_bind_fetch");
- mysqli_query($link,"CREATE TABLE test_bind_fetch(c1 tinyint,
- c2 tinyint unsigned,
- c3 tinyint not NULL,
- c4 tinyint,
- c5 tinyint,
- c6 tinyint unsigned,
- c7 tinyint)");
-
- mysqli_query($link, "INSERT INTO test_bind_fetch VALUES (-23,300,0,-100,-127,+30,0)");
-
- $stmt = mysqli_prepare($link, "SELECT * FROM test_bind_fetch");
- mysqli_bind_result($stmt, $c1, $c2, $c3, $c4, $c5, $c6, $c7);
- mysqli_execute($stmt);
- mysqli_fetch($stmt);
-
- $test = array($c1,$c2,$c3,$c4,$c5,$c6,$c7);
-
- var_dump($test);
-
- mysqli_stmt_close($stmt);
- mysqli_close($link);
-?>
---EXPECT--
-array(7) {
- [0]=>
- int(-23)
- [1]=>
- int(255)
- [2]=>
- int(0)
- [3]=>
- int(-100)
- [4]=>
- int(-127)
- [5]=>
- int(30)
- [6]=>
- int(0)
-}
diff --git a/ext/mysqli/tests/009.phpt b/ext/mysqli/tests/009.phpt
deleted file mode 100644
index d48b5157e9..0000000000
--- a/ext/mysqli/tests/009.phpt
+++ /dev/null
@@ -1,53 +0,0 @@
---TEST--
-mysqli fetch bigint values
---SKIPIF--
-<?php require_once('skipif.inc'); ?>
---FILE--
-<?php
- include "connect.inc";
-
- /*** test mysqli_connect 127.0.0.1 ***/
- $link = mysqli_connect($host, $user, $passwd);
-
- mysqli_select_db($link, "test");
-
- mysqli_query($link,"DROP TABLE IF EXISTS test_bind_fetch");
- mysqli_query($link,"CREATE TABLE test_bind_fetch(c1 bigint default 5,
- c2 bigint,
- c3 bigint not NULL,
- c4 bigint unsigned,
- c5 bigint unsigned,
- c6 bigint unsigned,
- c7 bigint unsigned)");
-
- mysqli_query($link, "INSERT INTO test_bind_fetch (c2,c3,c4,c5,c6,c7) VALUES (-23,4.0,33333333333333,0,-333333333333,99.9)");
-
- $stmt = mysqli_prepare($link, "SELECT * FROM test_bind_fetch");
- mysqli_bind_result($stmt, $c1, $c2, $c3, $c4, $c5, $c6, $c7);
- mysqli_execute($stmt);
- $rc = mysqli_fetch($stmt);
-
- $test = array($c1,$c2,$c3,$c4,$c5,$c6,$c7);
-
- var_dump($test);
-
- mysqli_stmt_close($stmt);
- mysqli_close($link);
-?>
---EXPECT--
-array(7) {
- [0]=>
- int(5)
- [1]=>
- int(-23)
- [2]=>
- int(4)
- [3]=>
- string(14) "33333333333333"
- [4]=>
- int(0)
- [5]=>
- string(13) "-333333333333"
- [6]=>
- int(100)
-}
diff --git a/ext/mysqli/tests/010.phpt b/ext/mysqli/tests/010.phpt
deleted file mode 100644
index 0d74bed501..0000000000
--- a/ext/mysqli/tests/010.phpt
+++ /dev/null
@@ -1,58 +0,0 @@
---TEST--
-mysqli fetch float values
---INI--
-precision=12
---SKIPIF--
-<?php require_once('skipif.inc'); ?>
---FILE--
-<?php
- include "connect.inc";
-
- /*** test mysqli_connect 127.0.0.1 ***/
- $link = mysqli_connect($host, $user, $passwd);
-
- mysqli_select_db($link, "test");
-
- mysqli_query($link,"DROP TABLE IF EXISTS test_bind_fetch");
-
- mysqli_query($link,"CREATE TABLE test_bind_fetch(c1 float(3),
- c2 float,
- c3 float unsigned,
- c4 float,
- c5 float,
- c6 float,
- c7 float(10) unsigned)");
-
-
- mysqli_query($link, "INSERT INTO test_bind_fetch (c1,c2,c3,c4,c5,c6,c7) VALUES (3.1415926535,-0.000001, -5, 999999999999,
- sin(0.6), 1.00000000000001, 888888888888888)");
-
- $stmt = mysqli_prepare($link, "SELECT * FROM test_bind_fetch");
- mysqli_bind_result($stmt, $c1, $c2, $c3, $c4, $c5, $c6, $c7);
- mysqli_execute($stmt);
- mysqli_fetch($stmt);
-
- $test = array($c1,$c2,$c3,$c4,$c5,$c6,$c7);
-
- var_dump($test);
-
- mysqli_stmt_close($stmt);
- mysqli_close($link);
-?>
---EXPECT--
-array(7) {
- [0]=>
- float(3.14159274101)
- [1]=>
- float(-9.99999997475E-7)
- [2]=>
- float(0)
- [3]=>
- float(999999995904)
- [4]=>
- float(0.564642488956)
- [5]=>
- float(1)
- [6]=>
- float(888888914608000)
-}
diff --git a/ext/mysqli/tests/011.phpt b/ext/mysqli/tests/011.phpt
deleted file mode 100644
index 77a157f564..0000000000
--- a/ext/mysqli/tests/011.phpt
+++ /dev/null
@@ -1,57 +0,0 @@
---TEST--
-mysqli fetch mixed values
---INI--
-precision=12
---SKIPIF--
-<?php require_once('skipif.inc'); ?>
---FILE--
-<?php
- include "connect.inc";
-
- /*** test mysqli_connect 127.0.0.1 ***/
- $link = mysqli_connect($host, $user, $passwd);
-
- mysqli_select_db($link, "test");
-
- mysqli_query($link,"DROP TABLE IF EXISTS test_bind_result");
-
- mysqli_query($link,"CREATE TABLE test_bind_result(c1 tinyint, c2 smallint,
- c3 int, c4 bigint,
- c5 float, c6 double,
- c7 varbinary(10),
- c8 varchar(50))");
-
- mysqli_query($link,"INSERT INTO test_bind_result VALUES(19,2999,3999,4999999,
- 2345.6,5678.89563,
- 'foobar','mysql rulez')");
- $stmt = mysqli_prepare($link, "SELECT * FROM test_bind_result");
- mysqli_bind_result($stmt, $c1, $c2, $c3, $c4, $c5, $c6, $c7, $c8);
- mysqli_execute($stmt);
- mysqli_fetch($stmt);
-
- $test = array($c1,$c2,$c3,$c4,$c5,$c6,$c7,$c8);
-
- var_dump($test);
-
- mysqli_stmt_close($stmt);
- mysqli_close($link);
-?>
---EXPECT--
-array(8) {
- [0]=>
- int(19)
- [1]=>
- int(2999)
- [2]=>
- int(3999)
- [3]=>
- int(4999999)
- [4]=>
- float(2345.60009766)
- [5]=>
- float(5678.89563)
- [6]=>
- string(6) "foobar"
- [7]=>
- string(11) "mysql rulez"
-}
diff --git a/ext/mysqli/tests/012.phpt b/ext/mysqli/tests/012.phpt
deleted file mode 100644
index 9c52f9c3e4..0000000000
--- a/ext/mysqli/tests/012.phpt
+++ /dev/null
@@ -1,58 +0,0 @@
---TEST--
-mysqli fetch mixed values 2
---INI--
-precision=12
---SKIPIF--
-<?php require_once('skipif.inc'); ?>
---FILE--
-<?php
- include "connect.inc";
-
- /*** test mysqli_connect 127.0.0.1 ***/
- $link = mysqli_connect($host, $user, $passwd);
-
- mysqli_select_db($link, "test");
-
- mysqli_query($link,"DROP TABLE IF EXISTS test_bind_result");
-
- mysqli_query($link,"CREATE TABLE test_bind_result(c1 tinyint, c2 smallint,
- c3 int, c4 bigint,
- c5 float, c6 double,
- c7 varbinary(10),
- c8 varchar(10))");
-
- mysqli_query($link,"INSERT INTO test_bind_result VALUES(120,2999,3999,54,
- 2.6,58.89,
- '206','6.7')");
-
- $stmt = mysqli_prepare($link, "SELECT * FROM test_bind_result");
- mysqli_bind_result($stmt, $c1, $c2, $c3, $c4, $c5, $c6, $c7, $c8);
- mysqli_execute($stmt);
- mysqli_fetch($stmt);
-
- $test = array($c1,$c2,$c3,$c4,$c5,$c6,$c7,$c8);
-
- var_dump($test);
-
- mysqli_stmt_close($stmt);
- mysqli_close($link);
-?>
---EXPECT--
-array(8) {
- [0]=>
- int(120)
- [1]=>
- int(2999)
- [2]=>
- int(3999)
- [3]=>
- int(54)
- [4]=>
- float(2.59999990463)
- [5]=>
- float(58.89)
- [6]=>
- string(3) "206"
- [7]=>
- string(3) "6.7"
-}
diff --git a/ext/mysqli/tests/013.phpt b/ext/mysqli/tests/013.phpt
deleted file mode 100644
index ff435f94db..0000000000
--- a/ext/mysqli/tests/013.phpt
+++ /dev/null
@@ -1,47 +0,0 @@
---TEST--
-mysqli fetch mixed / mysql_query
---SKIPIF--
-<?php require_once('skipif.inc'); ?>
---FILE--
-<?php
- include "connect.inc";
-
- /*** test mysqli_connect 127.0.0.1 ***/
- $link = mysqli_connect($host, $user, $passwd);
-
- mysqli_select_db($link, "test");
-
- mysqli_query($link,"DROP TABLE IF EXISTS test_bind_result");
-
- mysqli_query($link,"CREATE TABLE test_bind_result(c1 tinyint, c2 smallint,
- c3 int, c4 bigint,
- c5 decimal(4,2), c6 double,
- c7 varbinary(10),
- c8 varchar(10))");
-
- mysqli_query($link,"INSERT INTO test_bind_result VALUES(120,2999,3999,54,
- 2.6,58.89,
- '206','6.7')");
- $stmt = mysqli_prepare($link, "SELECT * FROM test_bind_result");
-
- $c = array(0,0,0,0,0,0,0,0);
- mysqli_bind_result($stmt, $c[0], $c[1], $c[2], $c[3], $c[4], $c[5], $c[6], $c[7]);
- mysqli_execute($stmt);
- mysqli_fetch($stmt);
- mysqli_fetch($stmt);
- mysqli_stmt_close($stmt);
-
- $result = mysqli_query($link, "select * from test_bind_result");
- $d = mysqli_fetch_row($result);
- mysqli_free_result($result);
-
- $test = "";
- for ($i=0; $i < count($c); $i++)
- $test .= ($c[0] == $d[0]) ? "1" : "0";
-
- var_dump($test);
-
- mysqli_close($link);
-?>
---EXPECT--
-string(8) "11111111"
diff --git a/ext/mysqli/tests/014.phpt b/ext/mysqli/tests/014.phpt
deleted file mode 100644
index a180bea756..0000000000
--- a/ext/mysqli/tests/014.phpt
+++ /dev/null
@@ -1,70 +0,0 @@
---TEST--
-mysqli autocommit/commit/rollback
---SKIPIF--
-<?php
- include "connect.inc";
- $link = mysqli_connect($host, $user, $passwd);
- $result = mysqli_query($link, "SHOW VARIABLES LIKE 'have_innodb'");
- $row = mysqli_fetch_row($result);
- mysqli_free_result($result);
- mysqli_close($link);
-
- if ($row[1] == "DISABLED" || $row[1] == "NO") {
- printf ("skip innodb support is not installed or enabled.");
- }
-?>
---SKIPIF--
-<?php require_once('skipif.inc'); ?>
---FILE--
-<?php
- include "connect.inc";
- $link = mysqli_connect($host, $user, $passwd);
-
- mysqli_select_db($link, "test");
-
- mysqli_autocommit($link, TRUE);
-
- mysqli_query($link,"DROP TABLE IF EXISTS ac_01");
-
- mysqli_query($link,"CREATE TABLE ac_01(a int, b varchar(10)) type=InnoDB");
-
- mysqli_query($link, "INSERT INTO ac_01 VALUES (1, 'foobar')");
- mysqli_autocommit($link, FALSE);
- mysqli_query($link, "DELETE FROM ac_01");
- mysqli_query($link, "INSERT INTO ac_01 VALUES (2, 'egon')");
-
- mysqli_rollback($link);
-
- $result = mysqli_query($link, "SELECT * FROM ac_01");
- printf("Num_of_rows=%d\n", mysqli_num_rows($result));
- $row = mysqli_fetch_row($result);
- mysqli_free_result($result);
-
- var_dump($row);
-
- mysqli_query($link, "DELETE FROM ac_01");
- mysqli_query($link, "INSERT INTO ac_01 VALUES (2, 'egon')");
- mysqli_commit($link);
-
- $result = mysqli_query($link, "SELECT * FROM ac_01");
- $row = mysqli_fetch_row($result);
- mysqli_free_result($result);
-
- var_dump($row);
-
- mysqli_close($link);
-?>
---EXPECT--
-Num_of_rows=1
-array(2) {
- [0]=>
- string(1) "1"
- [1]=>
- string(6) "foobar"
-}
-array(2) {
- [0]=>
- string(1) "2"
- [1]=>
- string(4) "egon"
-}
diff --git a/ext/mysqli/tests/015.phpt b/ext/mysqli/tests/015.phpt
deleted file mode 100644
index 26eb4383c9..0000000000
--- a/ext/mysqli/tests/015.phpt
+++ /dev/null
@@ -1,70 +0,0 @@
---TEST--
-mysqli autocommit/commit/rollback with myisam
---SKIPIF--
-<?php
- include "connect.inc";
- $link = mysqli_connect($host, $user, $passwd);
- $result = mysqli_query($link, "SHOW VARIABLES LIKE 'have_innodb'");
- $row = mysqli_fetch_row($result);
- mysqli_free_result($result);
- mysqli_close($link);
-
- if ($row[1] == "NO") {
- printf ("skip innodb support not installed.");
- }
-?>
---SKIPIF--
-<?php require_once('skipif.inc'); ?>
---FILE--
-<?php
- include "connect.inc";
-
- $link = mysqli_connect($host, $user, $passwd);
-
- mysqli_select_db($link, "test");
-
- mysqli_autocommit($link, TRUE);
-
- mysqli_query($link,"DROP TABLE IF EXISTS ac_01");
-
- mysqli_query($link,"CREATE TABLE ac_01(a int, b varchar(10))");
-
- mysqli_query($link, "INSERT INTO ac_01 VALUES (1, 'foobar')");
- mysqli_autocommit($link, FALSE);
-
- mysqli_query($link, "DELETE FROM ac_01");
- mysqli_query($link, "INSERT INTO ac_01 VALUES (2, 'egon')");
-
- mysqli_rollback($link);
-
- $result = mysqli_query($link, "SELECT * FROM ac_01");
- $row = mysqli_fetch_row($result);
- mysqli_free_result($result);
-
- var_dump($row);
-
- mysqli_query($link, "DELETE FROM ac_01");
- mysqli_query($link, "INSERT INTO ac_01 VALUES (2, 'egon')");
- mysqli_commit($link);
-
- $result = mysqli_query($link, "SELECT * FROM ac_01");
- $row = mysqli_fetch_row($result);
- mysqli_free_result($result);
-
- var_dump($row);
-
- mysqli_close($link);
-?>
---EXPECT--
-array(2) {
- [0]=>
- string(1) "2"
- [1]=>
- string(4) "egon"
-}
-array(2) {
- [0]=>
- string(1) "2"
- [1]=>
- string(4) "egon"
-}
diff --git a/ext/mysqli/tests/016.phpt b/ext/mysqli/tests/016.phpt
deleted file mode 100644
index c61da29ec1..0000000000
--- a/ext/mysqli/tests/016.phpt
+++ /dev/null
@@ -1,27 +0,0 @@
---TEST--
-mysqli fetch user variable
---SKIPIF--
-<?php require_once('skipif.inc'); ?>
---FILE--
-<?php
- include "connect.inc";
-
- /*** test mysqli_connect 127.0.0.1 ***/
- $link = mysqli_connect($host, $user, $passwd);
-
- mysqli_select_db($link, "test");
-
- mysqli_query($link, "SET @dummy='foobar'");
-
- $stmt = mysqli_prepare($link, "SELECT @dummy");
- mysqli_bind_result($stmt, $dummy);
- mysqli_execute($stmt);
- mysqli_fetch($stmt);
-
- var_dump($dummy);
-
- mysqli_stmt_close($stmt);
- mysqli_close($link);
-?>
---EXPECT--
-string(6) "foobar"
diff --git a/ext/mysqli/tests/017.phpt b/ext/mysqli/tests/017.phpt
deleted file mode 100644
index 54d11ef719..0000000000
--- a/ext/mysqli/tests/017.phpt
+++ /dev/null
@@ -1,37 +0,0 @@
---TEST--
-mysqli fetch functions
---SKIPIF--
-<?php require_once('skipif.inc'); ?>
-<?php require_once('skipifemb.inc'); ?>
---FILE--
-<?php
- include "connect.inc";
-
- /*** test mysqli_connect 127.0.0.1 ***/
- $link = mysqli_connect($host, $user, $passwd);
-
- mysqli_select_db($link, "test");
-
- $stmt = mysqli_prepare($link, "SELECT current_user(), database(), 'foo'");
- mysqli_bind_result($stmt, $c0, $c1, $c2);
- mysqli_execute($stmt);
-
- mysqli_fetch($stmt);
- mysqli_stmt_close($stmt);
-
- $c0 = ($c0 == $user . "@" . $host) ? 1 : 0;
-
- $test = array($c0, $c1, $c2);
-
- var_dump($test);
- mysqli_close($link);
-?>
---EXPECT--
-array(3) {
- [0]=>
- int(1)
- [1]=>
- string(4) "test"
- [2]=>
- string(3) "foo"
-}
diff --git a/ext/mysqli/tests/018.phpt b/ext/mysqli/tests/018.phpt
deleted file mode 100644
index 4ba199d866..0000000000
--- a/ext/mysqli/tests/018.phpt
+++ /dev/null
@@ -1,27 +0,0 @@
---TEST--
-mysqli fetch system variables
---SKIPIF--
-<?php require_once('skipif.inc'); ?>
---FILE--
-<?php
- include "connect.inc";
-
- /*** test mysqli_connect 127.0.0.1 ***/
- $link = mysqli_connect($host, $user, $passwd);
-
- mysqli_select_db($link, "test");
-
- mysqli_query($link, "SET AUTOCOMMIT=0");
-
- $stmt = mysqli_prepare($link, "SELECT @@autocommit");
- mysqli_bind_result($stmt, $c0);
- mysqli_execute($stmt);
-
- mysqli_fetch($stmt);
-
- var_dump($c0);
-
- mysqli_close($link);
-?>
---EXPECT--
-int(0)
diff --git a/ext/mysqli/tests/019.phpt b/ext/mysqli/tests/019.phpt
deleted file mode 100644
index 41b1ba2cf9..0000000000
--- a/ext/mysqli/tests/019.phpt
+++ /dev/null
@@ -1,70 +0,0 @@
---TEST--
-mysqli fetch (bind_param + bind_result)
---SKIPIF--
-<?php require_once('skipif.inc'); ?>
---FILE--
-<?php
- include "connect.inc";
-
- /*** test mysqli_connect 127.0.0.1 ***/
- $link = mysqli_connect($host, $user, $passwd);
-
- mysqli_select_db($link, "test");
- $rc = mysqli_query($link,"DROP TABLE IF EXISTS insert_read");
-
- $rc = mysqli_query($link,"CREATE TABLE insert_read(col1 tinyint, col2 smallint,
- col3 int, col4 bigint,
- col5 float, col6 double,
- col7 date, col8 time,
- col9 varbinary(10),
- col10 varchar(50),
- col11 char(20))");
-
- $stmt= mysqli_prepare($link,"INSERT INTO insert_read(col1,col10, col11) VALUES(?,?,?)");
- mysqli_bind_param($stmt, "iss", $c1, $c2, $c3);
-
- $c1 = 1;
- $c2 = "foo";
- $c3 = "foobar";
-
- mysqli_execute($stmt);
- mysqli_stmt_close($stmt);
-
- $stmt = mysqli_prepare($link, "SELECT col1, col2, col3, col4, col5, col6, col7, col8, col9, col10, col11 from insert_read");
- mysqli_bind_result($stmt, $c1, $c2, $c3, $c4, $c5, $c6, $c7, $c8, $c9, $c10, $c11);
- mysqli_execute($stmt);
-
- mysqli_fetch($stmt);
-
- $test = array($c1,$c2,$c3,$c4,$c5,$c6,$c7,$c8,$c9,$c10,$c11);
-
- var_dump($test);
-
- mysqli_stmt_close($stmt);
- mysqli_close($link);
-?>
---EXPECT--
-array(11) {
- [0]=>
- int(1)
- [1]=>
- NULL
- [2]=>
- NULL
- [3]=>
- NULL
- [4]=>
- NULL
- [5]=>
- NULL
- [6]=>
- NULL
- [7]=>
- NULL
- [8]=>
- NULL
- [9]=>
- string(3) "foo"
- [10]=>
- string(6) "foobar"
-}
diff --git a/ext/mysqli/tests/020.phpt b/ext/mysqli/tests/020.phpt
deleted file mode 100644
index 85834c52af..0000000000
--- a/ext/mysqli/tests/020.phpt
+++ /dev/null
@@ -1,66 +0,0 @@
---TEST--
-mysqli bind_param/bind_result date
---SKIPIF--
-<?php require_once('skipif.inc'); ?>
---FILE--
-<?php
- include "connect.inc";
-
- /*** test mysqli_connect 127.0.0.1 ***/
- $link = mysqli_connect($host, $user, $passwd);
-
- mysqli_select_db($link, "test");
-
- mysqli_query($link,"DROP TABLE IF EXISTS test_bind_result");
- mysqli_query($link,"CREATE TABLE test_bind_result(c1 date, c2 time,
- c3 timestamp(14),
- c4 year,
- c5 datetime,
- c6 timestamp(4),
- c7 timestamp(6))");
-
- $stmt = mysqli_prepare($link, "INSERT INTO test_bind_result VALUES (?,?,?,?,?,?,?)");
- mysqli_bind_param($stmt, "sssssss", $d1, $d2, $d3, $d4, $d5, $d6, $d7);
-
- $d1 = '2002-01-02';
- $d2 = '12:49:00';
- $d3 = '2002-01-02 17:46:59';
- $d4 = 2010;
- $d5 ='2010-07-10';
- $d6 = '2020';
- $d7 = '1999-12-29';
-
- mysqli_execute($stmt);
- mysqli_stmt_close($stmt);
-
- $stmt = mysqli_prepare($link, "SELECT * FROM test_bind_result");
-
- mysqli_bind_result($stmt,$c1, $c2, $c3, $c4, $c5, $c6, $c7);
-
- mysqli_execute($stmt);
- mysqli_fetch($stmt);
-
- $test = array($c1,$c2,$c3,$c4,$c5,$c6,$c7);
-
- var_dump($test);
-
- mysqli_stmt_close($stmt);
- mysqli_close($link);
-?>
---EXPECT--
-array(7) {
- [0]=>
- string(10) "2002-01-02"
- [1]=>
- string(8) "12:49:00"
- [2]=>
- string(19) "2002-01-02 17:46:59"
- [3]=>
- int(2010)
- [4]=>
- string(19) "2010-07-10 00:00:00"
- [5]=>
- string(19) "0000-00-00 00:00:00"
- [6]=>
- string(19) "1999-12-29 00:00:00"
-}
diff --git a/ext/mysqli/tests/021.phpt b/ext/mysqli/tests/021.phpt
deleted file mode 100644
index 6f5bad3205..0000000000
--- a/ext/mysqli/tests/021.phpt
+++ /dev/null
@@ -1,42 +0,0 @@
---TEST--
-mysqli bind_param+bind_result char/text
---SKIPIF--
-<?php require_once('skipif.inc'); ?>
---FILE--
-<?php
- include "connect.inc";
-
- /*** test mysqli_connect 127.0.0.1 ***/
- $link = mysqli_connect($host, $user, $passwd);
-
- mysqli_select_db($link, "test");
-
- mysqli_query($link,"DROP TABLE IF EXISTS test_bind_fetch");
- mysqli_query($link,"CREATE TABLE test_bind_fetch(c1 char(10), c2 text)");
-
- $stmt = mysqli_prepare($link, "INSERT INTO test_bind_fetch VALUES (?,?)");
- mysqli_bind_param($stmt, "ss", $q1, $q2);
- $q1 = "1234567890";
- $q2 = "this is a test";
- mysqli_execute($stmt);
- mysqli_stmt_close($stmt);
-
- $stmt = mysqli_prepare($link, "SELECT * FROM test_bind_fetch");
- mysqli_bind_result($stmt, $c1, $c2);
- mysqli_execute($stmt);
- mysqli_fetch($stmt);
-
- $test = array($c1,$c2);
-
- var_dump($test);
-
- mysqli_stmt_close($stmt);
- mysqli_close($link);
-?>
---EXPECT--
-array(2) {
- [0]=>
- string(10) "1234567890"
- [1]=>
- string(14) "this is a test"
-}
diff --git a/ext/mysqli/tests/022.phpt b/ext/mysqli/tests/022.phpt
deleted file mode 100644
index cce8ed8eb6..0000000000
--- a/ext/mysqli/tests/022.phpt
+++ /dev/null
@@ -1,46 +0,0 @@
---TEST--
-mysqli bind_param/bind_result char/text long
---SKIPIF--
-<?php require_once('skipif.inc'); ?>
---FILE--
-<?php
- include "connect.inc";
-
- /*** test mysqli_connect 127.0.0.1 ***/
- $link = mysqli_connect($host, $user, $passwd);
-
- mysqli_select_db($link, "test");
-
- mysqli_query($link,"DROP TABLE IF EXISTS test_bind_fetch");
- mysqli_query($link,"CREATE TABLE test_bind_fetch(c1 char(10), c2 text)");
-
-
- $stmt = mysqli_prepare($link, "INSERT INTO test_bind_fetch VALUES (?,?)");
- mysqli_bind_param($stmt, "ss", $a1, $a2);
-
- $a1 = "1234567890";
- $a2 = str_repeat("A1", 32000);
-
- mysqli_execute($stmt);
- mysqli_stmt_close($stmt);
-
- $stmt = mysqli_prepare($link, "SELECT * FROM test_bind_fetch");
- mysqli_bind_result($stmt, $c1, $c2);
- mysqli_execute($stmt);
- mysqli_fetch($stmt);
-
- $test[] = $c1;
- $test[] = ($a2 == $c2) ? "32K String ok" : "32K String failed";
-
- var_dump($test);
-
- mysqli_stmt_close($stmt);
- mysqli_close($link);
-?>
---EXPECT--
-array(2) {
- [0]=>
- string(10) "1234567890"
- [1]=>
- string(13) "32K String ok"
-}
diff --git a/ext/mysqli/tests/023.phpt b/ext/mysqli/tests/023.phpt
deleted file mode 100644
index 69e9b20858..0000000000
--- a/ext/mysqli/tests/023.phpt
+++ /dev/null
@@ -1,64 +0,0 @@
---TEST--
-mysqli bind_param/bind_prepare fetch long values
---SKIPIF--
-<?php require_once('skipif.inc'); ?>
---FILE--
-<?php
- include "connect.inc";
-
- /*** test mysqli_connect 127.0.0.1 ***/
- $link = mysqli_connect($host, $user, $passwd);
-
- mysqli_select_db($link, "test");
-
- mysqli_query($link,"DROP TABLE IF EXISTS test_bind_fetch");
- mysqli_query($link,"CREATE TABLE test_bind_fetch(c1 int unsigned,
- c2 int unsigned,
- c3 int,
- c4 int,
- c5 int,
- c6 int unsigned,
- c7 int)");
-
- $stmt = mysqli_prepare($link, "INSERT INTO test_bind_fetch VALUES (?,?,?,?,?,?,?)");
- mysqli_bind_param($stmt, "iiiiiii", $c1,$c2,$c3,$c4,$c5,$c6,$c7);
- $c1 = -23;
- $c2 = 35999;
- $c3 = NULL;
- $c4 = -500;
- $c5 = -9999999;
- $c6 = -0;
- $c7 = 0;
-
- mysqli_execute($stmt);
- mysqli_stmt_close($stmt);
-
- $stmt = mysqli_prepare($link, "SELECT * FROM test_bind_fetch");
- mysqli_bind_result($stmt, $c1, $c2, $c3, $c4, $c5, $c6, $c7);
- mysqli_execute($stmt);
- mysqli_fetch($stmt);
-
- $test = array($c1,$c2,$c3,$c4,$c5,$c6,$c7);
-
- var_dump($test);
-
- mysqli_stmt_close($stmt);
- mysqli_close($link);
-?>
---EXPECT--
-array(7) {
- [0]=>
- int(0)
- [1]=>
- int(35999)
- [2]=>
- NULL
- [3]=>
- int(-500)
- [4]=>
- int(-9999999)
- [5]=>
- int(0)
- [6]=>
- int(0)
-}
diff --git a/ext/mysqli/tests/024.phpt b/ext/mysqli/tests/024.phpt
deleted file mode 100644
index c6d6cd7e70..0000000000
--- a/ext/mysqli/tests/024.phpt
+++ /dev/null
@@ -1,65 +0,0 @@
---TEST--
-mysqli bind_param/bind_result short values
---SKIPIF--
-<?php require_once('skipif.inc'); ?>
---FILE--
-<?php
- include "connect.inc";
-
- /*** test mysqli_connect 127.0.0.1 ***/
- $link = mysqli_connect($host, $user, $passwd);
-
- mysqli_select_db($link, "test");
-
- mysqli_query($link,"DROP TABLE IF EXISTS test_bind_fetch");
- mysqli_query($link,"CREATE TABLE test_bind_fetch(c1 smallint unsigned,
- c2 smallint unsigned,
- c3 smallint,
- c4 smallint,
- c5 smallint,
- c6 smallint unsigned,
- c7 smallint)");
-
- $stmt = mysqli_prepare($link, "INSERT INTO test_bind_fetch VALUES (?,?,?,?,?,?,?)");
- mysqli_bind_param($stmt, "iiiiiii", $c1,$c2,$c3,$c4,$c5,$c6,$c7);
-
- $c1 = -23;
- $c2 = 35999;
- $c3 = NULL;
- $c4 = -500;
- $c5 = -9999999;
- $c6 = -0;
- $c7 = 0;
-
- mysqli_execute($stmt);
- mysqli_stmt_close($stmt);
-
- $stmt = mysqli_prepare($link, "SELECT * FROM test_bind_fetch");
- mysqli_bind_result($stmt, $c1, $c2, $c3, $c4, $c5, $c6, $c7);
- mysqli_execute($stmt);
- mysqli_fetch($stmt);
-
- $test = array($c1,$c2,$c3,$c4,$c5,$c6,$c7);
-
- var_dump($test);
-
- mysqli_stmt_close($stmt);
- mysqli_close($link);
-?>
---EXPECT--
-array(7) {
- [0]=>
- int(0)
- [1]=>
- int(35999)
- [2]=>
- NULL
- [3]=>
- int(-500)
- [4]=>
- int(-32768)
- [5]=>
- int(0)
- [6]=>
- int(0)
-}
diff --git a/ext/mysqli/tests/025.phpt b/ext/mysqli/tests/025.phpt
deleted file mode 100644
index 85ff0fa29f..0000000000
--- a/ext/mysqli/tests/025.phpt
+++ /dev/null
@@ -1,69 +0,0 @@
---TEST--
-mysqli bind_param/bind_result tinyint values
---SKIPIF--
-<?php require_once('skipif.inc'); ?>
---FILE--
-<?php
- include "connect.inc";
-
- /*** test mysqli_connect 127.0.0.1 ***/
- $link = mysqli_connect($host, $user, $passwd);
-
- mysqli_select_db($link, "test");
-
- mysqli_query($link,"DROP TABLE IF EXISTS test_bind_fetch");
- mysqli_query($link,"CREATE TABLE test_bind_fetch(c1 tinyint,
- c2 tinyint unsigned,
- c3 tinyint not NULL,
- c4 tinyint,
- c5 tinyint,
- c6 tinyint unsigned,
- c7 tinyint)");
-
- $stmt = mysqli_prepare ($link, "INSERT INTO test_bind_fetch VALUES(?,?,?,?,?,?,?)");
- mysqli_bind_param($stmt, "iiiiiii", $c1,$c2,$c3,$c4,$c5,$c6,$c7);
-
- $c1 = -23;
- $c2 = 300;
- $c3 = 0;
- $c4 = -100;
- $c5 = -127;
- $c6 = 30;
- $c7 = 0;
-
- mysqli_execute($stmt);
- mysqli_stmt_close($stmt);
-
- mysqli_query($link, "INSERT INTO test_bind_fetch VALUES (-23,300,0,-100,-127,+30,0)");
-
- $c1 = $c2 = $c3 = $c4 = $c5 = $c6 = $c7 = NULL;
-
- $stmt = mysqli_prepare($link, "SELECT * FROM test_bind_fetch");
- mysqli_bind_result($stmt, $c1, $c2, $c3, $c4, $c5, $c6, $c7);
- mysqli_execute($stmt);
- mysqli_fetch($stmt);
-
- $test = array($c1,$c2,$c3,$c4,$c5,$c6,$c7);
-
- var_dump($test);
-
- mysqli_stmt_close($stmt);
- mysqli_close($link);
-?>
---EXPECT--
-array(7) {
- [0]=>
- int(-23)
- [1]=>
- int(255)
- [2]=>
- int(0)
- [3]=>
- int(-100)
- [4]=>
- int(-127)
- [5]=>
- int(30)
- [6]=>
- int(0)
-}
diff --git a/ext/mysqli/tests/026.phpt b/ext/mysqli/tests/026.phpt
deleted file mode 100644
index 0f9e882608..0000000000
--- a/ext/mysqli/tests/026.phpt
+++ /dev/null
@@ -1,48 +0,0 @@
---TEST--
-mysqli bind_param/bind_result with send_long_data
---SKIPIF--
-<?php require_once('skipif.inc'); ?>
---FILE--
-<?php
- include "connect.inc";
-
- /*** test mysqli_connect 127.0.0.1 ***/
- $link = mysqli_connect($host, $user, $passwd);
-
- mysqli_select_db($link, "test");
-
- mysqli_query($link,"DROP TABLE IF EXISTS test_bind_fetch");
- mysqli_query($link,"CREATE TABLE test_bind_fetch(c1 varchar(10), c2 text)");
-
- $stmt = mysqli_prepare ($link, "INSERT INTO test_bind_fetch VALUES (?,?)");
- mysqli_bind_param($stmt, "sb", $c1, $c2);
-
- $c1 = "Hello World";
-
- mysqli_send_long_data($stmt, 1, "This is the first sentence.");
- mysqli_send_long_data($stmt, 1, " And this is the second sentence.");
- mysqli_send_long_data($stmt, 1, " And finally this is the last sentence.");
-
- mysqli_execute($stmt);
- mysqli_stmt_close($stmt);
-
- $stmt = mysqli_prepare($link, "SELECT * FROM test_bind_fetch");
- mysqli_bind_result($stmt, $d1, $d2);
- mysqli_execute($stmt);
- mysqli_fetch($stmt);
-
- $test = array($d1,$d2);
-
- var_dump($test);
-
- mysqli_stmt_close($stmt);
-
- mysqli_close($link);
-?>
---EXPECT--
-array(2) {
- [0]=>
- string(10) "Hello Worl"
- [1]=>
- string(99) "This is the first sentence. And this is the second sentence. And finally this is the last sentence."
-}
diff --git a/ext/mysqli/tests/027.phpt b/ext/mysqli/tests/027.phpt
deleted file mode 100644
index 9f8eadf9dd..0000000000
--- a/ext/mysqli/tests/027.phpt
+++ /dev/null
@@ -1,20 +0,0 @@
---TEST--
-function test: mysqli_stat
---SKIPIF--
-<?php require_once('skipif.inc'); ?>
---FILE--
-<?php
- include "connect.inc";
-
- /*** test mysqli_connect 127.0.0.1 ***/
- $link = mysqli_connect($host, $user, $passwd);
-
- $status = mysqli_stat($link);
-
-
- var_dump(strlen($status) > 0);
-
- mysqli_close($link);
-?>
---EXPECT--
-bool(true)
diff --git a/ext/mysqli/tests/028.phpt b/ext/mysqli/tests/028.phpt
deleted file mode 100644
index 021804540d..0000000000
--- a/ext/mysqli/tests/028.phpt
+++ /dev/null
@@ -1,19 +0,0 @@
---TEST--
-function test: mysqli_character_set_name
---SKIPIF--
-<?php require_once('skipif.inc'); ?>
---FILE--
-<?php
- include "connect.inc";
-
- /*** test mysqli_connect 127.0.0.1 ***/
- $link = mysqli_connect($host, $user, $passwd);
-
- $cset = substr(mysqli_character_set_name($link),0,6);
-
- var_dump($cset);
-
- mysqli_close($link);
-?>
---EXPECT--
-string(6) "latin1"
diff --git a/ext/mysqli/tests/029.phpt b/ext/mysqli/tests/029.phpt
deleted file mode 100644
index 318e6aeb9e..0000000000
--- a/ext/mysqli/tests/029.phpt
+++ /dev/null
@@ -1,25 +0,0 @@
---TEST--
-function test: mysqli_affected_rows
---SKIPIF--
-<?php require_once('skipif.inc'); ?>
---FILE--
-<?php
- include "connect.inc";
-
- /*** test mysqli_connect 127.0.0.1 ***/
- $link = mysqli_connect($host, $user, $passwd);
-
- mysqli_select_db($link, "test");
-
- mysqli_query($link, "drop table if exists general_test");
- mysqli_query($link, "create table general_test (a int)");
- mysqli_query($link, "insert into general_test values (1),(2),(3)");
-
- $afc = mysqli_affected_rows($link);
-
- var_dump($afc);
-
- mysqli_close($link);
-?>
---EXPECT--
-int(3)
diff --git a/ext/mysqli/tests/030.phpt b/ext/mysqli/tests/030.phpt
deleted file mode 100644
index a3946c3715..0000000000
--- a/ext/mysqli/tests/030.phpt
+++ /dev/null
@@ -1,25 +0,0 @@
---TEST--
-function test: mysqli_errno
---SKIPIF--
-<?php require_once('skipif.inc'); ?>
---FILE--
-<?php
- include "connect.inc";
-
- /*** test mysqli_connect 127.0.0.1 ***/
- $link = mysqli_connect($host, $user, $passwd);
- $errno = mysqli_errno($link);
- var_dump($errno);
-
- mysqli_select_db($link, "test");
-
- mysqli_query($link, "select * from non_exisiting_table");
- $errno = mysqli_errno($link);
-
- var_dump($errno);
-
- mysqli_close($link);
-?>
---EXPECT--
-int(0)
-int(1146)
diff --git a/ext/mysqli/tests/031.phpt b/ext/mysqli/tests/031.phpt
deleted file mode 100644
index 743b4b2d0f..0000000000
--- a/ext/mysqli/tests/031.phpt
+++ /dev/null
@@ -1,25 +0,0 @@
---TEST--
-function test: mysqli_error
---SKIPIF--
-<?php require_once('skipif.inc'); ?>
---FILE--
-<?php
- include "connect.inc";
-
- /*** test mysqli_connect 127.0.0.1 ***/
- $link = mysqli_connect($host, $user, $passwd);
- $error = mysqli_error($link);
- var_dump($error);
-
- mysqli_select_db($link, "test");
-
- mysqli_query($link, "select * from non_exisiting_table");
- $error = mysqli_error($link);
-
- var_dump($error);
-
- mysqli_close($link);
-?>
---EXPECT--
-string(0) ""
-string(46) "Table 'test.non_exisiting_table' doesn't exist"
diff --git a/ext/mysqli/tests/032.phpt b/ext/mysqli/tests/032.phpt
deleted file mode 100644
index 18bd756a23..0000000000
--- a/ext/mysqli/tests/032.phpt
+++ /dev/null
@@ -1,25 +0,0 @@
---TEST--
-function test: mysqli_info
---SKIPIF--
-<?php require_once('skipif.inc'); ?>
---FILE--
-<?php
- include "connect.inc";
-
- /*** test mysqli_connect 127.0.0.1 ***/
- $link = mysqli_connect($host, $user, $passwd);
-
- mysqli_select_db($link, "test");
-
- mysqli_query($link, "drop table if exists general_test");
- mysqli_query($link, "create table general_test (a int)");
- mysqli_query($link, "insert into general_test values (1),(2),(3)");
-
- $afc = mysqli_info($link);
-
- var_dump($afc);
-
- mysqli_close($link);
-?>
---EXPECT--
-string(38) "Records: 3 Duplicates: 0 Warnings: 0"
diff --git a/ext/mysqli/tests/033.phpt b/ext/mysqli/tests/033.phpt
deleted file mode 100644
index de401f49de..0000000000
--- a/ext/mysqli/tests/033.phpt
+++ /dev/null
@@ -1,20 +0,0 @@
---TEST--
-function test: mysqli_get_host_info
---SKIPIF--
-<?php require_once('skipif.inc'); ?>
-<?php require_once('skipifemb.inc'); ?>
---FILE--
-<?php
- include "connect.inc";
-
- /*** test mysqli_connect 127.0.0.1 ***/
- $link = mysqli_connect($host, $user, $passwd);
-
- $hinfo = mysqli_get_host_info($link);
-
- var_dump(str_replace('/','', $hinfo));
-
- mysqli_close($link);
-?>
---EXPECTF--
-string(%d) "%s via %s"
diff --git a/ext/mysqli/tests/034.phpt b/ext/mysqli/tests/034.phpt
deleted file mode 100644
index 468861c3c2..0000000000
--- a/ext/mysqli/tests/034.phpt
+++ /dev/null
@@ -1,20 +0,0 @@
---TEST--
-function test: mysqli_get_proto_info
---SKIPIF--
-<?php require_once('skipif.inc'); ?>
-<?php require_once('skipifemb.inc'); ?>
---FILE--
-<?php
- include "connect.inc";
-
- /*** test mysqli_connect 127.0.0.1 ***/
- $link = mysqli_connect($host, $user, $passwd);
-
- $pinfo = mysqli_get_proto_info($link);
-
- var_dump($pinfo);
-
- mysqli_close($link);
-?>
---EXPECT--
-int(10)
diff --git a/ext/mysqli/tests/035.phpt b/ext/mysqli/tests/035.phpt
deleted file mode 100644
index ea31222ec7..0000000000
--- a/ext/mysqli/tests/035.phpt
+++ /dev/null
@@ -1,19 +0,0 @@
---TEST--
-function test: mysqli_get_server_info
---SKIPIF--
-<?php require_once('skipif.inc'); ?>
---FILE--
-<?php
- include "connect.inc";
-
- /*** test mysqli_connect 127.0.0.1 ***/
- $link = mysqli_connect($host, $user, $passwd);
-
- $sinfo = substr(mysqli_get_server_info($link),0,1);
-
- var_dump(strlen($sinfo));
-
- mysqli_close($link);
-?>
---EXPECT--
-int(1)
diff --git a/ext/mysqli/tests/036.phpt b/ext/mysqli/tests/036.phpt
deleted file mode 100644
index 58d27b481e..0000000000
--- a/ext/mysqli/tests/036.phpt
+++ /dev/null
@@ -1,45 +0,0 @@
---TEST--
-function test: mysqli_insert_id()
---SKIPIF--
-<?php require_once('skipif.inc'); ?>
---FILE--
-<?php
-
- include "connect.inc";
-
- /*** test mysqli_connect 127.0.0.1 ***/
- $link = mysqli_connect($host, $user, $passwd);
-
- mysqli_select_db($link, "test");
-
- mysqli_query($link, "DROP TABLE IF EXISTS t036");
-
- mysqli_query($link, "CREATE TABLE t036 (a bigint not null auto_increment primary key, b varchar(10))");
-
-
- mysqli_query($link, "INSERT INTO t036 (b) VALUES ('foo1')");
- $test[] = mysqli_insert_id($link);
-
- /* we have to insert more values, cause lexer sets auto_increment to max_int
- see mysql bug #54. So we don't check for the value, only for type (which must
- be type string)
- */
-
- mysqli_query($link, "ALTER TABLE t036 AUTO_INCREMENT=9999999999999998");
- mysqli_query($link, "INSERT INTO t036 (b) VALUES ('foo2')");
- mysqli_query($link, "INSERT INTO t036 (b) VALUES ('foo3')");
- mysqli_query($link, "INSERT INTO t036 (b) VALUES ('foo4')");
- $x = mysqli_insert_id($link);
- $test[] = is_string($x);
-
- var_dump($test);
-
- mysqli_close($link);
-?>
---EXPECT--
-array(2) {
- [0]=>
- int(1)
- [1]=>
- bool(true)
-}
diff --git a/ext/mysqli/tests/037.phpt b/ext/mysqli/tests/037.phpt
deleted file mode 100644
index c9089c19be..0000000000
--- a/ext/mysqli/tests/037.phpt
+++ /dev/null
@@ -1,36 +0,0 @@
---TEST--
-function test: mysqli_field_count()
---SKIPIF--
-<?php require_once('skipif.inc'); ?>
---FILE--
-<?php
-
- include "connect.inc";
-
- /*** test mysqli_connect 127.0.0.1 ***/
- $link = mysqli_connect($host, $user, $passwd);
-
- mysqli_select_db($link, "test");
-
- mysqli_query($link, "DROP TABLE IF EXISTS test_result");
-
- mysqli_query($link, "CREATE TABLE test_result (a int, b varchar(10))");
-
- mysqli_query($link, "INSERT INTO test_result VALUES (1, 'foo')");
- $ir[] = mysqli_field_count($link);
-
- mysqli_real_query($link, "SELECT * FROM test_result");
- $ir[] = mysqli_field_count($link);
-
-
- var_dump($ir);
-
- mysqli_close($link);
-?>
---EXPECT--
-array(2) {
- [0]=>
- int(0)
- [1]=>
- int(2)
-}
diff --git a/ext/mysqli/tests/038.phpt b/ext/mysqli/tests/038.phpt
deleted file mode 100644
index ecd4f908f1..0000000000
--- a/ext/mysqli/tests/038.phpt
+++ /dev/null
@@ -1,33 +0,0 @@
---TEST--
-function test: mysqli_num_fields()
---SKIPIF--
-<?php require_once('skipif.inc'); ?>
---FILE--
-<?php
-
- include "connect.inc";
-
- /*** test mysqli_connect 127.0.0.1 ***/
- $link = mysqli_connect($host, $user, $passwd);
-
- mysqli_select_db($link, "test");
-
- mysqli_query($link, "DROP TABLE IF EXISTS test_result");
-
- mysqli_query($link, "CREATE TABLE test_result (a int, b varchar(10))");
-
- mysqli_query($link, "INSERT INTO test_result VALUES (1, 'foo')");
-
- mysqli_real_query($link, "SELECT * FROM test_result");
- if (mysqli_field_count($link)) {
- $result = mysqli_store_result($link);
- $num = mysqli_num_fields($result);
- mysqli_free_result($result);
- }
-
- var_dump($num);
-
- mysqli_close($link);
-?>
---EXPECT--
-int(2)
diff --git a/ext/mysqli/tests/039.phpt b/ext/mysqli/tests/039.phpt
deleted file mode 100644
index 1d5ab99106..0000000000
--- a/ext/mysqli/tests/039.phpt
+++ /dev/null
@@ -1,26 +0,0 @@
---TEST--
-function test: mysqli_num_fields() 2
---SKIPIF--
-<?php require_once('skipif.inc'); ?>
---FILE--
-<?php
-
- include "connect.inc";
-
- /*** test mysqli_connect 127.0.0.1 ***/
- $link = mysqli_connect($host, $user, $passwd);
-
- mysqli_real_query($link, "SHOW VARIABLES");
-
- if (mysqli_field_count($link)) {
- $result = mysqli_store_result($link);
- $num = mysqli_num_fields($result);
- mysqli_free_result($result);
- }
-
- var_dump($num);
-
- mysqli_close($link);
-?>
---EXPECT--
-int(2)
diff --git a/ext/mysqli/tests/040.phpt b/ext/mysqli/tests/040.phpt
deleted file mode 100644
index 79bfe0d5fb..0000000000
--- a/ext/mysqli/tests/040.phpt
+++ /dev/null
@@ -1,33 +0,0 @@
---TEST--
-function test: mysqli_num_rows()
---SKIPIF--
-<?php require_once('skipif.inc'); ?>
---FILE--
-<?php
-
- include "connect.inc";
-
- /*** test mysqli_connect 127.0.0.1 ***/
- $link = mysqli_connect($host, $user, $passwd);
-
- mysqli_select_db($link, "test");
-
- mysqli_query($link, "DROP TABLE IF EXISTS test_result");
-
- mysqli_query($link, "CREATE TABLE test_result (a int, b varchar(10))");
-
- mysqli_query($link, "INSERT INTO test_result VALUES (1, 'foo')");
-
- mysqli_real_query($link, "SELECT * FROM test_result");
- if (mysqli_field_count($link)) {
- $result = mysqli_store_result($link);
- $num = mysqli_num_rows($result);
- mysqli_free_result($result);
- }
-
- var_dump($num);
-
- mysqli_close($link);
-?>
---EXPECT--
-int(1)
diff --git a/ext/mysqli/tests/041.phpt b/ext/mysqli/tests/041.phpt
deleted file mode 100644
index d6a9f954d0..0000000000
--- a/ext/mysqli/tests/041.phpt
+++ /dev/null
@@ -1,26 +0,0 @@
---TEST--
-function test: mysqli_warning_count()
---SKIPIF--
-<?php require_once('skipif.inc'); ?>
---FILE--
-<?php
-
- include "connect.inc";
-
- /*** test mysqli_connect 127.0.0.1 ***/
- $link = mysqli_connect($host, $user, $passwd);
-
- mysqli_select_db($link, "test");
-
- mysqli_query($link, "DROP TABLE IF EXISTS test_warnings");
-
- mysqli_query($link, "CREATE TABLE test_warnings (a int not null");
- mysqli_query($link, "INSERT INTO test_warnings VALUES (NULL)");
-
- $num = mysqli_warning_count($link);
- var_dump($num);
-
- mysqli_close($link);
-?>
---EXPECT--
-int(1)
diff --git a/ext/mysqli/tests/042.phpt b/ext/mysqli/tests/042.phpt
deleted file mode 100644
index fe6d23e172..0000000000
--- a/ext/mysqli/tests/042.phpt
+++ /dev/null
@@ -1,61 +0,0 @@
---TEST--
-mysqli_fetch_object
---SKIPIF--
-<?php require_once('skipif.inc'); ?>
---FILE--
-<?php
- include "connect.inc";
-
- /*** test mysqli_connect 127.0.0.1 ***/
- $link = mysqli_connect($host, $user, $passwd);
-
- mysqli_select_db($link, "test");
-
- mysqli_query($link,"DROP TABLE IF EXISTS test_bind_fetch");
- mysqli_query($link,"CREATE TABLE test_bind_fetch(c1 smallint unsigned,
- c2 smallint unsigned,
- c3 smallint,
- c4 smallint,
- c5 smallint,
- c6 smallint unsigned,
- c7 smallint)");
-
- $stmt = mysqli_prepare($link, "INSERT INTO test_bind_fetch VALUES (?,?,?,?,?,?,?)");
- mysqli_bind_param($stmt, "iiiiiii", $c1,$c2,$c3,$c4,$c5,$c6,$c7);
-
- $c1 = -23;
- $c2 = 35999;
- $c3 = NULL;
- $c4 = -500;
- $c5 = -9999999;
- $c6 = -0;
- $c7 = 0;
-
- mysqli_execute($stmt);
- mysqli_stmt_close($stmt);
-
- $result = mysqli_query($link, "SELECT * FROM test_bind_fetch");
- $test = mysqli_fetch_object($result);
- mysqli_free_result($result);
-
- var_dump($test);
-
- mysqli_close($link);
-?>
---EXPECTF--
-object(stdClass)#%d (7) {
- ["c1"]=>
- string(1) "0"
- ["c2"]=>
- string(5) "35999"
- ["c3"]=>
- NULL
- ["c4"]=>
- string(4) "-500"
- ["c5"]=>
- string(6) "-32768"
- ["c6"]=>
- string(1) "0"
- ["c7"]=>
- string(1) "0"
-}
diff --git a/ext/mysqli/tests/043.phpt b/ext/mysqli/tests/043.phpt
deleted file mode 100644
index fb0284e06a..0000000000
--- a/ext/mysqli/tests/043.phpt
+++ /dev/null
@@ -1,42 +0,0 @@
---TEST--
-mysqli_bind_param (UPDATE)
---SKIPIF--
-<?php require_once('skipif.inc'); ?>
---FILE--
-<?php
- include "connect.inc";
-
- /*** test mysqli_connect 127.0.0.1 ***/
- $link = mysqli_connect($host, $user, $passwd);
-
- mysqli_select_db($link, "test");
-
- mysqli_query($link,"DROP TABLE IF EXISTS test_update");
- mysqli_query($link,"CREATE TABLE test_update(a varchar(10),
- b int)");
-
- mysqli_query($link, "INSERT INTO test_update VALUES ('foo', 2)");
-
- $stmt = mysqli_prepare($link, "UPDATE test_update SET a=?,b=? WHERE b=?");
- mysqli_bind_param($stmt, "sii", $c1, $c2, $c3);
-
- $c1 = "Rasmus";
- $c2 = 1;
- $c3 = 2;
-
- mysqli_execute($stmt);
- mysqli_stmt_close($stmt);
-
- $result = mysqli_query($link, "SELECT concat(a, ' is No. ', b) FROM test_update");
- $test = mysqli_fetch_row($result);
- mysqli_free_result($result);
-
- var_dump($test);
-
- mysqli_close($link);
-?>
---EXPECT--
-array(1) {
- [0]=>
- string(15) "Rasmus is No. 1"
-}
diff --git a/ext/mysqli/tests/044.phpt b/ext/mysqli/tests/044.phpt
deleted file mode 100644
index 28e73a7e09..0000000000
--- a/ext/mysqli/tests/044.phpt
+++ /dev/null
@@ -1,21 +0,0 @@
---TEST--
-mysqli_get_server_version
---SKIPIF--
-<?php require_once('skipif.inc'); ?>
---FILE--
-<?php
- include "connect.inc";
-
- /*** test mysqli_connect 127.0.0.1 ***/
- $link = mysqli_connect($host, $user, $passwd);
-
- $i = mysqli_get_server_version($link);
-
- $test = $i / $i;
-
- var_dump($test);
-
- mysqli_close($link);
-?>
---EXPECT--
-int(1)
diff --git a/ext/mysqli/tests/045.phpt b/ext/mysqli/tests/045.phpt
deleted file mode 100644
index 2f9490c282..0000000000
--- a/ext/mysqli/tests/045.phpt
+++ /dev/null
@@ -1,46 +0,0 @@
---TEST--
-mysqli_bind_result (SHOW)
---SKIPIF--
-<?php
- include "connect.inc";
- $link = mysqli_connect($host, $user, $passwd);
-
-
- $stmt = mysqli_prepare($link, "SHOW VARIABLES LIKE 'port'");
- mysqli_execute($stmt);
-
- if (!$stmt->field_count) {
- printf("skip SHOW command is not supported in prepared statements.");
- }
- $stmt->close();
- mysqli_close($link);
-?>
---SKIPIF--
-<?php require_once('skipif.inc'); ?>
-<?php require_once('skipifemb.inc'); ?>
---FILE--
-<?php
- include "connect.inc";
-
- /*** test mysqli_connect 127.0.0.1 ***/
- $link = mysqli_connect($host, $user, $passwd);
-
- $stmt = mysqli_prepare($link, "SHOW VARIABLES LIKE 'port'");
- mysqli_execute($stmt);
-
- mysqli_bind_result($stmt, $c1, $c2);
- mysqli_fetch($stmt);
- mysqli_stmt_close($stmt);
- $test = array ($c1,$c2);
-
- var_dump($test);
-
- mysqli_close($link);
-?>
---EXPECT--
-array(2) {
- [0]=>
- string(4) "port"
- [1]=>
- string(4) "3306"
-}
diff --git a/ext/mysqli/tests/046.phpt b/ext/mysqli/tests/046.phpt
deleted file mode 100644
index e88348bfa9..0000000000
--- a/ext/mysqli/tests/046.phpt
+++ /dev/null
@@ -1,33 +0,0 @@
---TEST--
-mysqli_stmt_affected_rows (delete)
---SKIPIF--
-<?php require_once('skipif.inc'); ?>
---FILE--
-<?php
- include "connect.inc";
-
- /*** test mysqli_connect 127.0.0.1 ***/
- $link = mysqli_connect($host, $user, $passwd);
-
- mysqli_select_db($link, "test");
-
- mysqli_query($link, "DROP TABLE IF EXISTS test_affected");
- mysqli_query($link, "CREATE TABLE test_affected (foo int)");
-
- mysqli_query($link, "INSERT INTO test_affected VALUES (1),(2),(3),(4),(5)");
-
- $stmt = mysqli_prepare($link, "DELETE FROM test_affected WHERE foo=?");
- mysqli_bind_param($stmt, "i", $c1);
-
- $c1 = 2;
-
- mysqli_execute($stmt);
- $x = mysqli_stmt_affected_rows($stmt);
-
- mysqli_stmt_close($stmt);
- var_dump($x==1);
-
- mysqli_close($link);
-?>
---EXPECT--
-bool(true)
diff --git a/ext/mysqli/tests/047.phpt b/ext/mysqli/tests/047.phpt
deleted file mode 100644
index 8663e8a641..0000000000
--- a/ext/mysqli/tests/047.phpt
+++ /dev/null
@@ -1,83 +0,0 @@
---TEST--
-mysqli_get_metadata
---SKIPIF--
-<?php require_once('skipif.inc'); ?>
---FILE--
-<?php
- include "connect.inc";
-
- /*** test mysqli_connect 127.0.0.1 ***/
- $link = mysqli_connect($host, $user, $passwd);
-
- mysqli_select_db($link, "test");
-
- mysqli_query($link, "DROP TABLE IF EXISTS test_affected");
- mysqli_query($link, "CREATE TABLE test_affected (foo int, bar varchar(10) character set latin1)");
-
- mysqli_query($link, "INSERT INTO test_affected VALUES (1, 'Zak'),(2, 'Greant')");
-
- $stmt = mysqli_prepare($link, "SELECT * FROM test_affected");
- mysqli_execute($stmt);
- $result = mysqli_get_metadata($stmt);
-
- $fields = mysqli_fetch_fields($result);
- mysqli_free_result($result);
-
- var_dump($fields);
-
- mysqli_stmt_close($stmt);
- mysqli_close($link);
-?>
---EXPECTF--
-array(2) {
- [0]=>
- object(stdClass)#5 (11) {
- ["name"]=>
- string(3) "foo"
- ["orgname"]=>
- string(3) "foo"
- ["table"]=>
- string(13) "test_affected"
- ["orgtable"]=>
- string(13) "test_affected"
- ["def"]=>
- string(0) ""
- ["max_length"]=>
- int(0)
- ["length"]=>
- int(11)
- ["charsetnr"]=>
- int(63)
- ["flags"]=>
- int(32768)
- ["type"]=>
- int(3)
- ["decimals"]=>
- int(0)
- }
- [1]=>
- object(stdClass)#6 (11) {
- ["name"]=>
- string(3) "bar"
- ["orgname"]=>
- string(3) "bar"
- ["table"]=>
- string(13) "test_affected"
- ["orgtable"]=>
- string(13) "test_affected"
- ["def"]=>
- string(0) ""
- ["max_length"]=>
- int(0)
- ["length"]=>
- int(10)
- ["charsetnr"]=>
- int(8)
- ["flags"]=>
- int(0)
- ["type"]=>
- int(253)
- ["decimals"]=>
- int(0)
- }
-}
diff --git a/ext/mysqli/tests/048.phpt b/ext/mysqli/tests/048.phpt
deleted file mode 100644
index 1cf5b67894..0000000000
--- a/ext/mysqli/tests/048.phpt
+++ /dev/null
@@ -1,62 +0,0 @@
---TEST--
-mysqli bind_result (OO-Style)
---SKIPIF--
-<?php require_once('skipif.inc'); ?>
---FILE--
-<?php
- include "connect.inc";
-
- /*** test mysqli_connect 127.0.0.1 ***/
- $mysql = mysqli_connect($host, $user, $passwd);
-
- $mysql->select_db("test");
- $mysql->query("DROP TABLE IF EXISTS test_fetch_null");
-
- $mysql->query("CREATE TABLE test_fetch_null(col1 tinyint, col2 smallint,
- col3 int, col4 bigint,
- col5 float, col6 double,
- col7 date, col8 time,
- col9 varbinary(10),
- col10 varchar(50),
- col11 char(20))");
-
- $mysql->query("INSERT INTO test_fetch_null(col1,col10, col11) VALUES(1,'foo1', 1000),(2,'foo2', 88),(3,'foo3', 389789)");
-
- $stmt = $mysql->prepare("SELECT col1, col2, col3, col4, col5, col6, col7, col8, col9, col10, col11 from test_fetch_null");
- $stmt->bind_result($c1, $c2, $c3, $c4, $c5, $c6, $c7, $c8, $c9, $c10, $c11);
- $stmt->execute();
-
- $stmt->fetch();
-
- $test = array($c1,$c2,$c3,$c4,$c5,$c6,$c7,$c8,$c9,$c10,$c11);
-
- var_dump($test);
-
- $stmt->close();
- $mysql->close();
-?>
---EXPECT--
-array(11) {
- [0]=>
- int(1)
- [1]=>
- NULL
- [2]=>
- NULL
- [3]=>
- NULL
- [4]=>
- NULL
- [5]=>
- NULL
- [6]=>
- NULL
- [7]=>
- NULL
- [8]=>
- NULL
- [9]=>
- string(4) "foo1"
- [10]=>
- string(4) "1000"
-}
diff --git a/ext/mysqli/tests/049.phpt b/ext/mysqli/tests/049.phpt
deleted file mode 100644
index 8d16c3d4c7..0000000000
--- a/ext/mysqli/tests/049.phpt
+++ /dev/null
@@ -1,24 +0,0 @@
---TEST--
-mysql_fetch_row (OO-Style)
---SKIPIF--
-<?php require_once('skipif.inc'); ?>
-<?php require_once('skipifemb.inc'); ?>
---FILE--
-<?php
- include "connect.inc";
-
- /*** test mysqli_connect 127.0.0.1 ***/
- $mysql = mysqli_connect($host, $user, $passwd);
-
- $mysql->select_db("test");
- $result = $mysql->query("SELECT CURRENT_USER()");
- $row = $result->fetch_row();
- $result->close();
-
- $ok = ($row[0] == $user . "@" . $host);
- var_dump($ok);
-
- $mysql->close();
-?>
---EXPECT--
-bool(true)
diff --git a/ext/mysqli/tests/050.phpt b/ext/mysqli/tests/050.phpt
deleted file mode 100644
index 5f923ccf34..0000000000
--- a/ext/mysqli/tests/050.phpt
+++ /dev/null
@@ -1,21 +0,0 @@
---TEST--
-non freed statement test
---SKIPIF--
-<?php require_once('skipif.inc'); ?>
---FILE--
-<?php
- include "connect.inc";
-
- /************************
- * non freed stamement
- ************************/
- $link = mysqli_connect($host, $user, $passwd);
-
- $stmt = mysqli_prepare($link, "SELECT CURRENT_USER()");
- mysqli_execute($stmt);
-
- mysqli_close($link);
- printf("Ok\n");
-?>
---EXPECT--
-Ok
diff --git a/ext/mysqli/tests/051.phpt b/ext/mysqli/tests/051.phpt
deleted file mode 100644
index ef378757f1..0000000000
--- a/ext/mysqli/tests/051.phpt
+++ /dev/null
@@ -1,22 +0,0 @@
---TEST--
-free statement after close
---SKIPIF--
-<?php require_once('skipif.inc'); ?>
---FILE--
-<?php
- include "connect.inc";
-
- /************************
- * free statement after close
- ************************/
- $link = mysqli_connect($host, $user, $passwd);
-
- $stmt1 = mysqli_prepare($link, "SELECT CURRENT_USER()");
- mysqli_execute($stmt1);
-
- mysqli_close($link);
- @mysqli_stmt_close($stmt1);
- printf("Ok\n");
-?>
---EXPECT--
-Ok
diff --git a/ext/mysqli/tests/052.phpt b/ext/mysqli/tests/052.phpt
deleted file mode 100644
index 3fa5dc8f17..0000000000
--- a/ext/mysqli/tests/052.phpt
+++ /dev/null
@@ -1,22 +0,0 @@
---TEST--
-call statement after close
---SKIPIF--
-<?php require_once('skipif.inc'); ?>
---FILE--
-<?php
- include "connect.inc";
-
- /************************
- * statement call after close
- ************************/
- $link = mysqli_connect($host, $user, $passwd);
-
- $stmt2 = mysqli_prepare($link, "SELECT CURRENT_USER()");
-
- mysqli_close($link);
- @mysqli_execute($stmt2);
- @mysqli_stmt_close($stmt2);
- printf("Ok\n");
-?>
---EXPECT--
-Ok
diff --git a/ext/mysqli/tests/053.phpt b/ext/mysqli/tests/053.phpt
deleted file mode 100644
index 99148c7e80..0000000000
--- a/ext/mysqli/tests/053.phpt
+++ /dev/null
@@ -1,20 +0,0 @@
---TEST--
-not freed resultset
---SKIPIF--
-<?php require_once('skipif.inc'); ?>
---FILE--
-<?php
- include "connect.inc";
-
- /************************
- * non freed resultset
- ************************/
- $link = mysqli_connect($host, $user, $passwd);
-
- $result = mysqli_query($link, "SELECT CURRENT_USER()");
- mysqli_close($link);
- printf("Ok\n");
-
-?>
---EXPECT--
-Ok
diff --git a/ext/mysqli/tests/054.phpt b/ext/mysqli/tests/054.phpt
deleted file mode 100644
index 727b87ef8e..0000000000
--- a/ext/mysqli/tests/054.phpt
+++ /dev/null
@@ -1,20 +0,0 @@
---TEST--
-free resultset after close
---SKIPIF--
-<?php require_once('skipif.inc'); ?>
---FILE--
-<?php
- include "connect.inc";
-
- /************************
- * free resultset after close
- ************************/
- $link = mysqli_connect($host, $user, $passwd);
-
- $result1 = mysqli_query($link, "SELECT CURRENT_USER()");
- mysqli_close($link);
- mysqli_free_result($result1);
- printf("Ok\n");
-?>
---EXPECT--
-Ok
diff --git a/ext/mysqli/tests/055.phpt b/ext/mysqli/tests/055.phpt
deleted file mode 100644
index e650dbcecd..0000000000
--- a/ext/mysqli/tests/055.phpt
+++ /dev/null
@@ -1,19 +0,0 @@
---TEST--
-free nothing
---SKIPIF--
-<?php require_once('skipif.inc'); ?>
---FILE--
-<?php
- include "connect.inc";
-
- /************************
- * don't free anything
- ************************/
- $link = mysqli_connect($host, $user, $passwd);
-
- $result2 = mysqli_query($link, "SELECT CURRENT_USER()");
- $stmt2 = mysqli_prepare($link, "SELECT CURRENT_USER()");
- printf("Ok\n");
-?>
---EXPECT--
-Ok
diff --git a/ext/mysqli/tests/056.phpt b/ext/mysqli/tests/056.phpt
deleted file mode 100644
index cc5c32fc60..0000000000
--- a/ext/mysqli/tests/056.phpt
+++ /dev/null
@@ -1,21 +0,0 @@
---TEST--
-extend mysqli
---SKIPIF--
-<?php require_once('skipif.inc'); ?>
---FILE--
-<?php
- include "connect.inc";
-
- class foobar extends mysqli {
- function test () {
- return ("I like MySQL 4.1");
- }
- }
-
- $foo = new foobar();
- $foo->connect($host, $user, $passwd);
- $foo->close();
- printf("%s\n", $foo->test());
-?>
---EXPECT--
-I like MySQL 4.1
diff --git a/ext/mysqli/tests/057.phpt b/ext/mysqli/tests/057.phpt
deleted file mode 100644
index a987c72381..0000000000
--- a/ext/mysqli/tests/057.phpt
+++ /dev/null
@@ -1,54 +0,0 @@
---TEST--
-mysqli_get_metadata
---SKIPIF--
-<?php require_once('skipif.inc'); ?>
---FILE--
-<?php
- include "connect.inc";
-
- /*** test mysqli_connect 127.0.0.1 ***/
- $link = mysqli_connect($host, $user, $passwd);
-
- mysqli_select_db($link, "test");
-
- mysqli_query($link,"DROP TABLE IF EXISTS test_store_result");
- mysqli_query($link,"CREATE TABLE test_store_result (a int)");
-
- mysqli_query($link, "INSERT INTO test_store_result VALUES (1),(2),(3)");
-
- $stmt = mysqli_prepare($link, "SELECT * FROM test_store_result");
- mysqli_execute($stmt);
-
- /* this should produce an out of sync error */
- if ($result = mysqli_query($link, "SELECT * FROM test_store_result")) {
- mysqli_free_result($result);
- printf ("Query ok\n");
- }
- mysqli_stmt_close($stmt);
-
- $stmt = mysqli_prepare($link, "SELECT * FROM test_store_result");
- mysqli_execute($stmt);
- $result1 = mysqli_get_metadata($stmt);
- mysqli_stmt_store_result($stmt);
-
- printf ("Rows: %d\n", mysqli_stmt_affected_rows($stmt));
-
- /* this should show an error, cause results are not buffered */
- if ($result = mysqli_query($link, "SELECT * FROM test_store_result")) {
- $row = mysqli_fetch_row($result);
- mysqli_free_result($result);
- }
-
-
- var_dump($row);
-
- mysqli_free_result($result1);
- mysqli_stmt_close($stmt);
- mysqli_close($link);
-?>
---EXPECT--
-Rows: 3
-array(1) {
- [0]=>
- string(1) "1"
-}
diff --git a/ext/mysqli/tests/058.phpt b/ext/mysqli/tests/058.phpt
deleted file mode 100644
index 7554d08f68..0000000000
--- a/ext/mysqli/tests/058.phpt
+++ /dev/null
@@ -1,57 +0,0 @@
---TEST--
-multiple binds
---SKIPIF--
-<?php require_once('skipif.inc'); ?>
---FILE--
-<?php
- include "connect.inc";
-
- /*** test mysqli_connect 127.0.0.1 ***/
- $link = mysqli_connect($host, $user, $passwd);
-
- mysqli_select_db($link, "test");
-
- mysqli_query($link,"DROP TABLE IF EXISTS mbind");
- mysqli_query($link,"CREATE TABLE mbind (a int, b varchar(10))");
-
- $stmt = mysqli_prepare($link, "INSERT INTO mbind VALUES (?,?)");
-
- mysqli_bind_param($stmt, "is", $a, $b);
-
- $a = 1;
- $b = "foo";
-
- mysqli_execute($stmt);
-
- mysqli_bind_param($stmt, "is", $c, $d);
-
- $c = 2;
- $d = "bar";
-
- mysqli_execute($stmt);
- mysqli_stmt_close($stmt);
-
- $stmt = mysqli_prepare($link, "SELECT * FROM mbind");
- mysqli_execute($stmt);
-
- mysqli_bind_result($stmt, $e, $f);
- mysqli_fetch($stmt);
-
- mysqli_bind_result($stmt, $g, $h);
- mysqli_fetch($stmt);
-
- var_dump((array($e,$f,$g,$h)));
-
- mysqli_close($link);
-?>
---EXPECT--
-array(4) {
- [0]=>
- int(1)
- [1]=>
- string(3) "foo"
- [2]=>
- int(2)
- [3]=>
- string(3) "bar"
-}
diff --git a/ext/mysqli/tests/059.phpt b/ext/mysqli/tests/059.phpt
deleted file mode 100644
index 0bc8a62bbf..0000000000
--- a/ext/mysqli/tests/059.phpt
+++ /dev/null
@@ -1,41 +0,0 @@
---TEST--
-sqlmode + bind
---SKIPIF--
-<?php require_once('skipif.inc'); ?>
---FILE--
-<?php
- include "connect.inc";
-
- /*** test mysqli_connect 127.0.0.1 ***/
- $link = mysqli_connect($host, $user, $passwd);
-
- mysqli_select_db($link, "test");
-
- mysqli_query($link, "SET SQL_MODE='PIPES_AS_CONCAT'");
-
- mysqli_query($link,"DROP TABLE IF EXISTS mbind");
- mysqli_query($link,"CREATE TABLE mbind (b varchar(25))");
-
- $stmt = mysqli_prepare($link, "INSERT INTO mbind VALUES (?||?)");
-
- mysqli_bind_param($stmt, "ss", $a, $b);
-
- $a = "foo";
- $b = "bar";
-
- mysqli_execute($stmt);
-
- mysqli_stmt_close($stmt);
-
- $stmt = mysqli_prepare($link, "SELECT * FROM mbind");
- mysqli_execute($stmt);
-
- mysqli_bind_result($stmt, $e);
- mysqli_fetch($stmt);
-
- var_dump($e);
-
- mysqli_close($link);
-?>
---EXPECT--
-string(6) "foobar"
diff --git a/ext/mysqli/tests/060.phpt b/ext/mysqli/tests/060.phpt
deleted file mode 100644
index 875130dc55..0000000000
--- a/ext/mysqli/tests/060.phpt
+++ /dev/null
@@ -1,59 +0,0 @@
---TEST--
-mysqli_fetch_object with classes
---SKIPIF--
-<?php require_once('skipif.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);
-
- mysqli_select_db($link, "test");
-
- 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)");
-
- $result = mysqli_query($link, "SELECT * FROM test_bind_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--
-test_class::__construct(1,2)
-object(test_class)#%d (7) {
- ["c1"]=>
- string(1) "0"
- ["c2"]=>
- string(5) "35999"
- ["c3"]=>
- NULL
- ["c4"]=>
- string(4) "-500"
- ["c5"]=>
- string(6) "-32768"
- ["c6"]=>
- string(1) "0"
- ["c7"]=>
- string(1) "0"
-}
-Done
diff --git a/ext/mysqli/tests/061.phpt b/ext/mysqli/tests/061.phpt
deleted file mode 100644
index caee2e49bb..0000000000
--- a/ext/mysqli/tests/061.phpt
+++ /dev/null
@@ -1,42 +0,0 @@
---TEST--
-local infile handler
---SKIPIF--
-<?php require_once('skipif.inc'); ?>
-<?php require_once('skipifemb.inc'); ?>
---FILE--
-<?php
- include "connect.inc";
-
- function my_read($fp, &$buffer, $buflen, &$error) {
- $buffer = strrev(fread($fp, $buflen));
- return(strlen($buffer));
- }
-
- /*** test mysqli_connect 127.0.0.1 ***/
- $link = mysqli_connect($host, $user, $passwd, "test");
-
- /* create temporary file */
- $fp = fopen("061.csv", "w");
- fwrite($fp, "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))");
-
- mysqli_query($link, "LOAD DATA LOCAL INFILE '061.csv' INTO TABLE t_061 FIELDS TERMINATED BY ';'");
-
- mysqli_set_local_infile_handler($link, "my_read");
- mysqli_query($link, "LOAD DATA LOCAL INFILE '061.csv' INTO TABLE t_061 FIELDS TERMINATED BY ';'");
-
- 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]);
- }
- mysqli_free_result($result);
- }
-
- mysqli_close($link);
-?>
---EXPECT--
-foo-bar
-rab-oof
diff --git a/ext/mysqli/tests/062.phpt b/ext/mysqli/tests/062.phpt
deleted file mode 100644
index 962abce162..0000000000
--- a/ext/mysqli/tests/062.phpt
+++ /dev/null
@@ -1,25 +0,0 @@
---TEST--
-resultset constructor
---SKIPIF--
-<?php require_once('skipif.inc'); ?>
---FILE--
-<?php
- include "connect.inc";
-
- $mysql = new mysqli($host, $user, $passwd);
-
- $mysql->real_query("SELECT 'foo' FROM DUAL");
-
- $myresult = new mysqli_result($mysql);
-
- $row = $myresult->fetch_row();
- $myresult->close();
- $mysql->close();
-
- var_dump($row);
-?>
---EXPECT--
-array(1) {
- [0]=>
- string(3) "foo"
-}
diff --git a/ext/mysqli/tests/063.phpt b/ext/mysqli/tests/063.phpt
deleted file mode 100644
index 9dd01629aa..0000000000
--- a/ext/mysqli/tests/063.phpt
+++ /dev/null
@@ -1,21 +0,0 @@
---TEST--
-resultset constructor
---SKIPIF--
-<?php require_once('skipif.inc'); ?>
---FILE--
-<?php
- include "connect.inc";
-
- $mysql = new mysqli($host, $user, $passwd);
-
- $stmt = new mysqli_stmt($mysql, "SELECT 'foo' FROM DUAL");
- $stmt->execute();
- $stmt->bind_result($foo);
- $stmt->fetch();
- $stmt->close();
- $mysql->close();
-
- var_dump($foo);
-?>
---EXPECT--
-string(3) "foo"
diff --git a/ext/mysqli/tests/064.phpt b/ext/mysqli/tests/064.phpt
deleted file mode 100644
index e6df1e4505..0000000000
--- a/ext/mysqli/tests/064.phpt
+++ /dev/null
@@ -1,21 +0,0 @@
---TEST--
-NULL binding
---SKIPIF--
-<?php require_once('skipif.inc'); ?>
---FILE--
-<?php
- include "connect.inc";
-
- $mysql = new mysqli($host, $user, $passwd);
-
- $stmt = new mysqli_stmt($mysql, "SELECT NULL FROM DUAL");
- $stmt->execute();
- $stmt->bind_result($foo);
- $stmt->fetch();
- $stmt->close();
- $mysql->close();
-
- var_dump($foo);
-?>
---EXPECT--
-NULL
diff --git a/ext/mysqli/tests/065.phpt b/ext/mysqli/tests/065.phpt
deleted file mode 100644
index 950a10a437..0000000000
--- a/ext/mysqli/tests/065.phpt
+++ /dev/null
@@ -1,37 +0,0 @@
---TEST--
-set character set
---SKIPIF--
-<?php
-require_once('skipif.inc');
-?>
---FILE--
-<?php
- include "connect.inc";
-
- $mysql = new mysqli($host, $user, $passwd);
-
- $esc_str = chr(0xbf) . chr(0x5c);
-
- if ($mysql->set_charset("latin1")) {
- /* 5C should be escaped */
- $len[0] = strlen($mysql->real_escape_string($esc_str));
- $charset[0] = $mysql->client_encoding();
- }
-
- 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();
- }
-
- $mysql->close();
- var_dump($len[0]);
- var_dump($len[1]);
- var_dump($charset[0]);
- var_dump($charset[1]);
-?>
---EXPECT--
-int(3)
-int(2)
-string(6) "latin1"
-string(3) "gbk"
diff --git a/ext/mysqli/tests/bug28817.phpt b/ext/mysqli/tests/bug28817.phpt
deleted file mode 100644
index 0cc8b13612..0000000000
--- a/ext/mysqli/tests/bug28817.phpt
+++ /dev/null
@@ -1,39 +0,0 @@
---TEST--
-Bug #28817 testcase (properties)
---SKIPIF--
-<?php require_once('skipif.inc'); ?>
---FILE--
-<?php
- include "connect.inc";
-
- class my_mysql extends mysqli {
- public $p_test;
-
- function __construct() {
- $this->p_test[] = "foo";
- $this->p_test[] = "bar";
- }
- }
-
-
- $mysql = new my_mysql();
-
- var_dump($mysql->p_test);
- @var_dump($mysql->errno);
-
- $mysql->connect($host, $user, $passwd);
- $mysql->select_db("nonexistingdb");
-
- var_dump($mysql->errno > 0);
-
- $mysql->close();
-?>
---EXPECTF--
-array(2) {
- [0]=>
- string(3) "foo"
- [1]=>
- string(3) "bar"
-}
-NULL
-bool(true)
diff --git a/ext/mysqli/tests/bug29311.phpt b/ext/mysqli/tests/bug29311.phpt
deleted file mode 100644
index b50de178b2..0000000000
--- a/ext/mysqli/tests/bug29311.phpt
+++ /dev/null
@@ -1,48 +0,0 @@
---TEST--
-constructor test
---SKIPIF--
-<?php require_once('skipif.inc'); ?>
---FILE--
-<?php
- include "connect.inc";
-
- /* class 1 calls parent constructor */
- class mysql1 extends mysqli {
- function __construct() {
- global $host, $user, $passwd;
- parent::__construct($host, $user, $passwd, "test");
- }
- }
-
- /* class 2 has an own constructor */
- class mysql2 extends mysqli {
-
- function __construct() {
- global $host, $user, $passwd;
- $this->connect($host, $user, $passwd, "test");
- }
- }
-
- /* class 3 has no constructor */
- class mysql3 extends mysqli {
-
- }
-
- $foo[0] = new mysql1();
- $foo[1] = new mysql2();
- $foo[2] = new mysql3($host, $user, $passwd, "test");
-
-
- for ($i=0; $i < 3; $i++) {
- if (($result = $foo[$i]->query("SELECT DATABASE()"))) {
- $row = $result->fetch_row();
- printf("%d: %s\n", $i, $row[0]);
- $result->close();
- }
- $foo[$i]->close();
- }
-?>
---EXPECTF--
-0: test
-1: test
-2: test
diff --git a/ext/mysqli/tests/bug30967.phpt b/ext/mysqli/tests/bug30967.phpt
deleted file mode 100644
index 0a82d0d43c..0000000000
--- a/ext/mysqli/tests/bug30967.phpt
+++ /dev/null
@@ -1,23 +0,0 @@
---TEST--
-Bug #30967 testcase (properties)
---SKIPIF--
-<?php require_once('skipif.inc'); ?>
---FILE--
-<?php
- include "connect.inc";
-
- class mysql1 extends mysqli {
- }
-
- class mysql2 extends mysql1 {
- }
-
- $mysql = new mysql2($host, $user, $passwd, "test");
-
- $mysql->query("THIS DOES NOT WORK");
- printf("%d\n", $mysql->errno);
-
- $mysql->close();
-?>
---EXPECTF--
-1064
diff --git a/ext/mysqli/tests/bug31141.phpt b/ext/mysqli/tests/bug31141.phpt
deleted file mode 100644
index acad79f1f9..0000000000
--- a/ext/mysqli/tests/bug31141.phpt
+++ /dev/null
@@ -1,28 +0,0 @@
---TEST--
-Bug #31141 testcase (properties)
---SKIPIF--
-<?php require_once('skipif.inc'); ?>
---FILE--
-<?php
-class Test extends mysqli
-{
- public $test = array();
-
- function foo()
- {
- $ar_test = array("foo", "bar");
- $this->test = &$ar_test;
- }
-}
-
-$my_test = new Test;
-$my_test->foo();
-var_dump($my_test->test);
-?>
---EXPECTF--
-array(2) {
- [0]=>
- string(3) "foo"
- [1]=>
- string(3) "bar"
-}
diff --git a/ext/mysqli/tests/bug31668.phpt b/ext/mysqli/tests/bug31668.phpt
deleted file mode 100644
index b813096a2a..0000000000
--- a/ext/mysqli/tests/bug31668.phpt
+++ /dev/null
@@ -1,56 +0,0 @@
---TEST--
-Bug #31668 multi_query works exactly every other time (multi_query was global, now per connection)
---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();
- }
- } while ($mysql->next_result());
- var_dump($mysql->error, __LINE__);
- $mysql->close();
-
- $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();
- }
- } while ($mysql->next_result());
- var_dump($mysql->error, __LINE__);
-?>
---EXPECTF--
-array(1) {
- [1]=>
- string(1) "1"
-}
-array(1) {
- [2]=>
- string(1) "2"
-}
-string(0) ""
-int(%d)
-array(1) {
- [1]=>
- string(1) "1"
-}
-array(1) {
- [2]=>
- string(1) "2"
-}
-string(0) ""
-int(%d)
diff --git a/ext/mysqli/tests/bug32405.phpt b/ext/mysqli/tests/bug32405.phpt
deleted file mode 100644
index 9b58e3611b..0000000000
--- a/ext/mysqli/tests/bug32405.phpt
+++ /dev/null
@@ -1,38 +0,0 @@
---TEST--
-Bug #32405
---SKIPIF--
-<?php require_once('skipif.inc'); ?>
---FILE--
-<?php
- include ("connect.inc");
-
- /*** test mysqli_connect 127.0.0.1 ***/
- $link = mysqli_connect($host, $user, $passwd);
- mysqli_select_db($link, "test");
-
- /* two fields are needed. the problem does not occur with 1 field only selected. */
- $link->query("CREATE TABLE test_users(user_id int(10) unsigned NOT NULL auto_increment, login varchar(50) default '', PRIMARY KEY (user_id))");
- $link->query('INSERT INTO test_users VALUES (NULL, "user1"), (NULL, "user2"), (NULL, "user3"), (NULL, "user4")');
-
-
- if ($stmt = $link->prepare("SELECT SQL_NO_CACHE user_id, login FROM test_users")) {
- $stmt->execute();
- $stmt->bind_result($col1, $col2);
- while ($stmt->fetch()) {
- var_dump($col1, $col2);
- }
- $stmt->close();
- }
-
- mysqli_query($link,"DROP TABLE test_users");
- mysqli_close($link);
-?>
---EXPECT--
-int(1)
-string(5) "user1"
-int(2)
-string(5) "user2"
-int(3)
-string(5) "user3"
-int(4)
-string(5) "user4"
diff --git a/ext/mysqli/tests/bug33090.phpt b/ext/mysqli/tests/bug33090.phpt
deleted file mode 100644
index 5c1cba961e..0000000000
--- a/ext/mysqli/tests/bug33090.phpt
+++ /dev/null
@@ -1,21 +0,0 @@
---TEST--
-Bug #33090
---SKIPIF--
-<?php require_once('skipif.inc'); ?>
---FILE--
-<?php
- include ("connect.inc");
-
- /*** test mysqli_connect 127.0.0.1 ***/
- $link = mysqli_connect($host, $user, $passwd);
- mysqli_select_db($link, "test");
-
- if (!($link->prepare("this makes no sense"))) {
- printf("%d\n", $link->errno);
- printf("%s\n", $link->sqlstate);
- }
- $link->close();
-?>
---EXPECT--
-1064
-42000
diff --git a/ext/mysqli/tests/connect.inc b/ext/mysqli/tests/connect.inc
deleted file mode 100644
index fb538558bb..0000000000
--- a/ext/mysqli/tests/connect.inc
+++ /dev/null
@@ -1,23 +0,0 @@
-<?php
-
- /* default values are localhost, root and empty password
- Change the values if you use another configuration */
- $driver = new mysqli_driver;
-
- if (!$driver->embedded) {
- $host = "localhost";
- $user = "root";
- $passwd = "";
- } else {
- $path = realpath('./ext/mysqli/tests');
- $host = $user = $passwd = NULL;
- $args = array(
- "--datadir=$path",
- "--innodb_data_home_dir=$path",
- "--innodb_data_file_path=ibdata1:10M:autoextend",
- "--log-error=$path/testrun.log"
- );
- $driver->embedded_server_start(TRUE, $args, NULL);
- }
-
-?>
diff --git a/ext/mysqli/tests/skipif.inc b/ext/mysqli/tests/skipif.inc
deleted file mode 100644
index 5562aab84b..0000000000
--- a/ext/mysqli/tests/skipif.inc
+++ /dev/null
@@ -1,5 +0,0 @@
-<?php
-if (!extension_loaded('mysqli')){
- die('skip mysqli extension not available');
-}
-?>
diff --git a/ext/mysqli/tests/skipifemb.inc b/ext/mysqli/tests/skipifemb.inc
deleted file mode 100644
index 298c7219a6..0000000000
--- a/ext/mysqli/tests/skipifemb.inc
+++ /dev/null
@@ -1,5 +0,0 @@
-<?php
- $driver = new mysqli_driver();
- if ($driver->embedded)
- die("skip test doesn't run with embedded server");
-?>