summaryrefslogtreecommitdiff
path: root/ext/mysql
diff options
context:
space:
mode:
authorAdam Harvey <aharvey@php.net>2012-12-10 22:12:09 +0800
committerAdam Harvey <aharvey@php.net>2012-12-10 22:12:09 +0800
commitb7091aaf0137d97cf4aa4a402ec50b3946d369c0 (patch)
tree52618e911add69133e2f2eff4c976e9fe9ecd999 /ext/mysql
parentc007ba4740e90a7a73bc8c6350804670e4b49cc1 (diff)
downloadphp-git-b7091aaf0137d97cf4aa4a402ec50b3946d369c0.tar.gz
Deprecate ext/mysql.
Per https://wiki.php.net/rfc/mysql_deprecation, connecting to a MySQL database via ext/mysql now generates an E_DEPRECATED error. This commit includes the minimal EXPECTF updates required for the test suite to pass: it may be preferable to refactor some of the tests to suppress deprecation errors in situations where no other error is expected from mysql_[p]connect(), but I'm not enough of a MySQL expert to want to get my hands that dirty in a long standing test suite.
Diffstat (limited to 'ext/mysql')
-rw-r--r--ext/mysql/php_mysql.c4
-rw-r--r--ext/mysql/tests/001.phpt3
-rw-r--r--ext/mysql/tests/002.phpt1
-rw-r--r--ext/mysql/tests/003.phpt1
-rw-r--r--ext/mysql/tests/bug47438.phpt3
-rw-r--r--ext/mysql/tests/bug48754.phpt8
-rw-r--r--ext/mysql/tests/bug51242.phpt1
-rw-r--r--ext/mysql/tests/bug53649.phpt5
-rw-r--r--ext/mysql/tests/bug55473.phpt11
-rw-r--r--ext/mysql/tests/mysql_affected_rows.phpt1
-rw-r--r--ext/mysql/tests/mysql_client_encoding.phpt1
-rw-r--r--ext/mysql/tests/mysql_close.phpt1
-rw-r--r--ext/mysql/tests/mysql_connect.phpt20
-rw-r--r--ext/mysql/tests/mysql_constants.phpt3
-rw-r--r--ext/mysql/tests/mysql_create_db.phpt3
-rw-r--r--ext/mysql/tests/mysql_data_seek.phpt2
-rw-r--r--ext/mysql/tests/mysql_db_name.phpt2
-rw-r--r--ext/mysql/tests/mysql_db_query.phpt1
-rw-r--r--ext/mysql/tests/mysql_deprecated_api.phpt3
-rw-r--r--ext/mysql/tests/mysql_drop_db.phpt3
-rw-r--r--ext/mysql/tests/mysql_errno.phpt1
-rw-r--r--ext/mysql/tests/mysql_error.phpt2
-rw-r--r--ext/mysql/tests/mysql_fetch_array.phpt1
-rw-r--r--ext/mysql/tests/mysql_fetch_assoc.phpt3
-rw-r--r--ext/mysql/tests/mysql_fetch_field.phpt1
-rw-r--r--ext/mysql/tests/mysql_fetch_lengths.phpt1
-rw-r--r--ext/mysql/tests/mysql_fetch_object.phpt1
-rw-r--r--ext/mysql/tests/mysql_fetch_row.phpt3
-rw-r--r--ext/mysql/tests/mysql_field_flags.phpt2
-rw-r--r--ext/mysql/tests/mysql_field_len.phpt2
-rw-r--r--ext/mysql/tests/mysql_field_name.phpt2
-rw-r--r--ext/mysql/tests/mysql_field_seek.phpt2
-rw-r--r--ext/mysql/tests/mysql_field_table.phpt2
-rw-r--r--ext/mysql/tests/mysql_field_type.phpt2
-rw-r--r--ext/mysql/tests/mysql_free_result.phpt1
-rw-r--r--ext/mysql/tests/mysql_get_host_info.phpt1
-rw-r--r--ext/mysql/tests/mysql_get_proto_info.phpt1
-rw-r--r--ext/mysql/tests/mysql_get_server_info.phpt1
-rw-r--r--ext/mysql/tests/mysql_info.phpt3
-rw-r--r--ext/mysql/tests/mysql_insert_id.phpt2
-rw-r--r--ext/mysql/tests/mysql_list_dbs.phpt3
-rw-r--r--ext/mysql/tests/mysql_list_fields.phpt1
-rw-r--r--ext/mysql/tests/mysql_list_processes.phpt3
-rw-r--r--ext/mysql/tests/mysql_list_tables.phpt1
-rw-r--r--ext/mysql/tests/mysql_max_links.phpt12
-rw-r--r--ext/mysql/tests/mysql_max_persistent.phpt8
-rw-r--r--ext/mysql/tests/mysql_mysqlnd_read_timeout_long.phpt3
-rw-r--r--ext/mysql/tests/mysql_num_fields.phpt2
-rw-r--r--ext/mysql/tests/mysql_num_rows.phpt2
-rw-r--r--ext/mysql/tests/mysql_pconn_disable.phpt9
-rw-r--r--ext/mysql/tests/mysql_pconn_kill.phpt7
-rw-r--r--ext/mysql/tests/mysql_pconn_max_links.phpt5
-rw-r--r--ext/mysql/tests/mysql_pconn_reuse.phpt11
-rw-r--r--ext/mysql/tests/mysql_pconnect.phpt12
-rw-r--r--ext/mysql/tests/mysql_ping.phpt1
-rw-r--r--ext/mysql/tests/mysql_query.phpt1
-rw-r--r--ext/mysql/tests/mysql_query_load_data_openbasedir.phpt3
-rw-r--r--ext/mysql/tests/mysql_real_escape_string.phpt1
-rw-r--r--ext/mysql/tests/mysql_result.phpt2
-rw-r--r--ext/mysql/tests/mysql_select_db.phpt1
-rw-r--r--ext/mysql/tests/mysql_set_charset.phpt1
-rw-r--r--ext/mysql/tests/mysql_stat.phpt2
-rw-r--r--ext/mysql/tests/mysql_tablename.phpt2
-rw-r--r--ext/mysql/tests/mysql_thread_id.phpt4
-rw-r--r--ext/mysql/tests/mysql_trace_mode.phpt1
-rw-r--r--ext/mysql/tests/mysql_unbuffered_query.phpt1
66 files changed, 193 insertions, 17 deletions
diff --git a/ext/mysql/php_mysql.c b/ext/mysql/php_mysql.c
index f1aab94f8a..dc7f108b5d 100644
--- a/ext/mysql/php_mysql.c
+++ b/ext/mysql/php_mysql.c
@@ -731,6 +731,10 @@ static void php_mysql_do_connect(INTERNAL_FUNCTION_PARAMETERS, int persistent)
zend_bool free_host=0, new_link=0;
long connect_timeout;
+ php_error_docref(NULL TSRMLS_CC,
+ E_DEPRECATED,
+ "The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead");
+
#if !defined(MYSQL_USE_MYSQLND)
if ((MYSQL_VERSION_ID / 100) != (mysql_get_client_version() / 100)) {
php_error_docref(NULL TSRMLS_CC, E_WARNING,
diff --git a/ext/mysql/tests/001.phpt b/ext/mysql/tests/001.phpt
index 72b6614771..8782fd1252 100644
--- a/ext/mysql/tests/001.phpt
+++ b/ext/mysql/tests/001.phpt
@@ -29,5 +29,8 @@ var_dump($test);
print "done!";
?>
--EXPECTF--
+Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
+
+Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
%unicode|string%(2) "11"
done!
diff --git a/ext/mysql/tests/002.phpt b/ext/mysql/tests/002.phpt
index 8355c5f11e..8f53f4d724 100644
--- a/ext/mysql/tests/002.phpt
+++ b/ext/mysql/tests/002.phpt
@@ -37,6 +37,7 @@ print "done!";
require_once("clean_table.inc");
?>
--EXPECTF--
+Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
resource(%d) of type (mysql link)
bool(true)
bool(true)
diff --git a/ext/mysql/tests/003.phpt b/ext/mysql/tests/003.phpt
index 2d0b68b9f8..365abc20e9 100644
--- a/ext/mysql/tests/003.phpt
+++ b/ext/mysql/tests/003.phpt
@@ -57,6 +57,7 @@ print "done!";
require_once("clean_table.inc");
?>
--EXPECTF--
+Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
==stdClass==
object(stdClass)#%d (1) {
[%u|b%"a"]=>
diff --git a/ext/mysql/tests/bug47438.phpt b/ext/mysql/tests/bug47438.phpt
index 11f0ff33b8..fa7b3e6a2b 100644
--- a/ext/mysql/tests/bug47438.phpt
+++ b/ext/mysql/tests/bug47438.phpt
@@ -46,7 +46,8 @@ if (!mysql_select_db($db, $link) ||
mysql_close($link);
?>
---EXPECT--
+--EXPECTF--
+Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
0.a
1.b
2.c
diff --git a/ext/mysql/tests/bug48754.phpt b/ext/mysql/tests/bug48754.phpt
index fb322f4615..b461db3320 100644
--- a/ext/mysql/tests/bug48754.phpt
+++ b/ext/mysql/tests/bug48754.phpt
@@ -68,6 +68,8 @@ var_dump($link);
?>
--EXPECTF--
Explicit connection on close
+
+Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
Expect same thread id for $link and default conn: bool(true)
resource(%d) of type (mysql link)
resource(%d) of type (Unknown)
@@ -75,18 +77,24 @@ resource(%d) of type (Unknown)
Warning: mysql_close(): no MySQL-Link resource supplied in %s on line %d
Closing default link
+
+Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
Expect same thread id for $link and default conn but not the previous: bool(true)
resource(%d) of type (mysql link)
resource(%d) of type (mysql link)
resource(%d) of type (Unknown)
Explicit resource and pconnect
+
+Deprecated: mysql_pconnect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
resource(%d) of type (mysql link persistent)
resource(%d) of type (Unknown)
Warning: mysql_close(): no MySQL-Link resource supplied in %s on line %d
Default link and pconnect
+
+Deprecated: mysql_pconnect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
resource(%d) of type (mysql link persistent)
resource(%d) of type (mysql link persistent)
resource(%d) of type (Unknown)
diff --git a/ext/mysql/tests/bug51242.phpt b/ext/mysql/tests/bug51242.phpt
index 9b62cdb4cd..6801d3021f 100644
--- a/ext/mysql/tests/bug51242.phpt
+++ b/ext/mysql/tests/bug51242.phpt
@@ -35,4 +35,5 @@ if ($link = my_mysql_connect($host, $user, $passwd, $db, null, $socket)) {
}
?>
--EXPECTF--
+Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
resource(%d) of type (mysql link)
diff --git a/ext/mysql/tests/bug53649.phpt b/ext/mysql/tests/bug53649.phpt
index 70bf9bed36..7ccdf08e5f 100644
--- a/ext/mysql/tests/bug53649.phpt
+++ b/ext/mysql/tests/bug53649.phpt
@@ -67,5 +67,6 @@ mysql_close($link);
unlink('bug53649.data');
?>
---EXPECT--
-done \ No newline at end of file
+--EXPECTF--
+Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
+done
diff --git a/ext/mysql/tests/bug55473.phpt b/ext/mysql/tests/bug55473.phpt
index df584bdef9..1cc2dc9282 100644
--- a/ext/mysql/tests/bug55473.phpt
+++ b/ext/mysql/tests/bug55473.phpt
@@ -68,12 +68,21 @@ mysql.allow_persistent=1
print "done!";
?>
--EXPECTF--
+Deprecated: mysql_pconnect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
[003] reconnect 0
+
+Deprecated: mysql_pconnect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
[005] Setting openened files...
[003] reconnect 1
+
+Deprecated: mysql_pconnect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
[007] Opened files as expected
[003] reconnect 2
+
+Deprecated: mysql_pconnect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
[007] Opened files as expected
[003] reconnect 3
+
+Deprecated: mysql_pconnect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
[007] Opened files as expected
-done! \ No newline at end of file
+done!
diff --git a/ext/mysql/tests/mysql_affected_rows.phpt b/ext/mysql/tests/mysql_affected_rows.phpt
index 145e1f5c0b..2449ac416e 100644
--- a/ext/mysql/tests/mysql_affected_rows.phpt
+++ b/ext/mysql/tests/mysql_affected_rows.phpt
@@ -122,4 +122,5 @@ print "done!";
require_once("clean_table.inc");
?>
--EXPECTF--
+Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
done!
diff --git a/ext/mysql/tests/mysql_client_encoding.phpt b/ext/mysql/tests/mysql_client_encoding.phpt
index 8aa67a03ac..5b21765ddb 100644
--- a/ext/mysql/tests/mysql_client_encoding.phpt
+++ b/ext/mysql/tests/mysql_client_encoding.phpt
@@ -67,4 +67,5 @@ if (false !== ($tmp = @mysql_client_encoding($link)))
print "done!";
?>
--EXPECTF--
+Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
done!
diff --git a/ext/mysql/tests/mysql_close.phpt b/ext/mysql/tests/mysql_close.phpt
index 8f305ba780..e676511961 100644
--- a/ext/mysql/tests/mysql_close.phpt
+++ b/ext/mysql/tests/mysql_close.phpt
@@ -36,4 +36,5 @@ if (false !== ($tmp = @mysql_query("SELECT 1", $link)))
print "done!\n";
?>
--EXPECTF--
+Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
done!
diff --git a/ext/mysql/tests/mysql_connect.phpt b/ext/mysql/tests/mysql_connect.phpt
index 7158248040..2b73092375 100644
--- a/ext/mysql/tests/mysql_connect.phpt
+++ b/ext/mysql/tests/mysql_connect.phpt
@@ -104,5 +104,25 @@ if (!ini_get('sql.safe_mode')) {
print "done!";
?>
--EXPECTF--
+Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
+
+Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
+
+Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
+
Warning: mysql_connect(): Access denied for user '%s'@'%s' (using password: YES) in %s on line %d
+
+Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
+
+Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
+
+Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
+
+Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
+
+Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
+
+Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
+
+Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
done!
diff --git a/ext/mysql/tests/mysql_constants.phpt b/ext/mysql/tests/mysql_constants.phpt
index 1346100209..e68774503c 100644
--- a/ext/mysql/tests/mysql_constants.phpt
+++ b/ext/mysql/tests/mysql_constants.phpt
@@ -62,4 +62,5 @@ if (!empty($expected_constants)) {
print "done!";
?>
--EXPECTF--
-done! \ No newline at end of file
+Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
+done!
diff --git a/ext/mysql/tests/mysql_create_db.phpt b/ext/mysql/tests/mysql_create_db.phpt
index bc91964f50..0b6d58a09e 100644
--- a/ext/mysql/tests/mysql_create_db.phpt
+++ b/ext/mysql/tests/mysql_create_db.phpt
@@ -53,4 +53,7 @@ if (!mysql_query("DROP DATABASE IF EXISTS mysqlcreatedb", $link))
mysql_close($link);
?>
--EXPECTF--
+Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
+
+Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
done!
diff --git a/ext/mysql/tests/mysql_data_seek.phpt b/ext/mysql/tests/mysql_data_seek.phpt
index 46a0f86bde..72d3e63274 100644
--- a/ext/mysql/tests/mysql_data_seek.phpt
+++ b/ext/mysql/tests/mysql_data_seek.phpt
@@ -67,6 +67,8 @@ print "done!\n";
require_once("clean_table.inc");
?>
--EXPECTF--
+Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
+
Warning: mysql_data_seek(): Offset 4 is invalid for MySQL result index %d (or the query data is unbuffered) in %s on line %d
Warning: mysql_data_seek(): Offset -1 is invalid for MySQL result index %d (or the query data is unbuffered) in %s on line %d
diff --git a/ext/mysql/tests/mysql_db_name.phpt b/ext/mysql/tests/mysql_db_name.phpt
index b7f9042209..92878e994d 100644
--- a/ext/mysql/tests/mysql_db_name.phpt
+++ b/ext/mysql/tests/mysql_db_name.phpt
@@ -58,6 +58,8 @@ mysql_close($link);
print "done!\n";
?>
--EXPECTF--
+Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
+
Warning: mysql_db_name(): Unable to jump to row -1 on MySQL result index %d in %s on line %d
Warning: mysql_db_name(): Unable to jump to row %d on MySQL result index %d in %s on line %d
diff --git a/ext/mysql/tests/mysql_db_query.phpt b/ext/mysql/tests/mysql_db_query.phpt
index bb837dd6c0..291fbfaac6 100644
--- a/ext/mysql/tests/mysql_db_query.phpt
+++ b/ext/mysql/tests/mysql_db_query.phpt
@@ -62,4 +62,5 @@ print "done!\n";
require_once("clean_table.inc");
?>
--EXPECTF--
+Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
done!
diff --git a/ext/mysql/tests/mysql_deprecated_api.phpt b/ext/mysql/tests/mysql_deprecated_api.phpt
index d54307ca0e..ebf72375cf 100644
--- a/ext/mysql/tests/mysql_deprecated_api.phpt
+++ b/ext/mysql/tests/mysql_deprecated_api.phpt
@@ -75,4 +75,5 @@ print "done!";
require_once("clean_table.inc");
?>
--EXPECTF--
-done! \ No newline at end of file
+Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
+done!
diff --git a/ext/mysql/tests/mysql_drop_db.phpt b/ext/mysql/tests/mysql_drop_db.phpt
index bd729e7ab8..3281b8a333 100644
--- a/ext/mysql/tests/mysql_drop_db.phpt
+++ b/ext/mysql/tests/mysql_drop_db.phpt
@@ -52,4 +52,5 @@ if (!mysql_query("DROP DATABASE IF EXISTS mysqldropdb", $link))
mysql_close($link);
?>
--EXPECTF--
-done! \ No newline at end of file
+Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
+done!
diff --git a/ext/mysql/tests/mysql_errno.phpt b/ext/mysql/tests/mysql_errno.phpt
index 8cfa7bd33b..c9c2956290 100644
--- a/ext/mysql/tests/mysql_errno.phpt
+++ b/ext/mysql/tests/mysql_errno.phpt
@@ -55,6 +55,7 @@ print "done!";
require_once("clean_table.inc");
?>
--EXPECTF--
+Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
int(0)
int(%d)
diff --git a/ext/mysql/tests/mysql_error.phpt b/ext/mysql/tests/mysql_error.phpt
index aae4480174..a2cf7e0034 100644
--- a/ext/mysql/tests/mysql_error.phpt
+++ b/ext/mysql/tests/mysql_error.phpt
@@ -62,6 +62,8 @@ print "done!";
require_once("clean_table.inc");
?>
--EXPECTF--
+Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
+
Warning: mysql_error(): %d is not a valid MySQL-Link resource in %s on line %d
bool(false)
done!
diff --git a/ext/mysql/tests/mysql_fetch_array.phpt b/ext/mysql/tests/mysql_fetch_array.phpt
index 362cf99ddc..8ccefd0242 100644
--- a/ext/mysql/tests/mysql_fetch_array.phpt
+++ b/ext/mysql/tests/mysql_fetch_array.phpt
@@ -281,6 +281,7 @@ print "done!";
require_once("clean_table.inc");
?>
--EXPECTF--
+Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
[005]
array(4) {
[0]=>
diff --git a/ext/mysql/tests/mysql_fetch_assoc.phpt b/ext/mysql/tests/mysql_fetch_assoc.phpt
index 3c5ca79b2d..048613a6be 100644
--- a/ext/mysql/tests/mysql_fetch_assoc.phpt
+++ b/ext/mysql/tests/mysql_fetch_assoc.phpt
@@ -63,6 +63,7 @@ print "done!";
require_once("clean_table.inc");
?>
--EXPECTF--
+Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
[005]
array(2) {
[%u|b%"id"]=>
@@ -87,6 +88,8 @@ array(5) {
}
Warning: mysql_fetch_assoc(): %d is not a valid MySQL result resource in %s on line %d
+
+Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
[010]
array(5) {
[%u|b%"id"]=>
diff --git a/ext/mysql/tests/mysql_fetch_field.phpt b/ext/mysql/tests/mysql_fetch_field.phpt
index ef03279087..85c1fd6f7e 100644
--- a/ext/mysql/tests/mysql_fetch_field.phpt
+++ b/ext/mysql/tests/mysql_fetch_field.phpt
@@ -156,6 +156,7 @@ require_once('skipifconnectfailure.inc');
require_once("clean_table.inc");
?>
--EXPECTF--
+Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
object(stdClass)#%d (13) {
[%u|b%"name"]=>
%unicode|string%(2) "ID"
diff --git a/ext/mysql/tests/mysql_fetch_lengths.phpt b/ext/mysql/tests/mysql_fetch_lengths.phpt
index 4793e2649b..f0fbbb7bb8 100644
--- a/ext/mysql/tests/mysql_fetch_lengths.phpt
+++ b/ext/mysql/tests/mysql_fetch_lengths.phpt
@@ -39,6 +39,7 @@ print "done!";
require_once("clean_table.inc");
?>
--EXPECTF--
+Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
array(2) {
[0]=>
int(1)
diff --git a/ext/mysql/tests/mysql_fetch_object.phpt b/ext/mysql/tests/mysql_fetch_object.phpt
index c11631e04c..666d0ee821 100644
--- a/ext/mysql/tests/mysql_fetch_object.phpt
+++ b/ext/mysql/tests/mysql_fetch_object.phpt
@@ -82,6 +82,7 @@ print "done!";
require_once("clean_table.inc");
?>
--EXPECTF--
+Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
object(stdClass)#%d (2) {
[%u|b%"ID"]=>
%unicode|string%(1) "1"
diff --git a/ext/mysql/tests/mysql_fetch_row.phpt b/ext/mysql/tests/mysql_fetch_row.phpt
index 8d6b9585be..0ed932e2c0 100644
--- a/ext/mysql/tests/mysql_fetch_row.phpt
+++ b/ext/mysql/tests/mysql_fetch_row.phpt
@@ -41,6 +41,7 @@ print "done!";
require_once("clean_table.inc");
?>
--EXPECTF--
+Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
[004]
array(2) {
[0]=>
@@ -53,4 +54,4 @@ bool(false)
Warning: mysql_fetch_row(): %d is not a valid MySQL result resource in %s on line %d
bool(false)
-done! \ No newline at end of file
+done!
diff --git a/ext/mysql/tests/mysql_field_flags.phpt b/ext/mysql/tests/mysql_field_flags.phpt
index e07e041d2a..7f1b366d5c 100644
--- a/ext/mysql/tests/mysql_field_flags.phpt
+++ b/ext/mysql/tests/mysql_field_flags.phpt
@@ -144,6 +144,8 @@ print "done!";
require_once("clean_table.inc");
?>
--EXPECTF--
+Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
+
Warning: mysql_field_flags() expects exactly 2 parameters, 1 given in %s on line %d
Warning: mysql_field_flags(): Field -1 is invalid for MySQL result index %d in %s on line %d
diff --git a/ext/mysql/tests/mysql_field_len.phpt b/ext/mysql/tests/mysql_field_len.phpt
index a740c62439..119d352164 100644
--- a/ext/mysql/tests/mysql_field_len.phpt
+++ b/ext/mysql/tests/mysql_field_len.phpt
@@ -47,6 +47,8 @@ print "done!";
require_once("clean_table.inc");
?>
--EXPECTF--
+Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
+
Warning: mysql_field_len() expects exactly 2 parameters, 1 given in %s on line %d
Warning: mysql_field_len(): Field -1 is invalid for MySQL result index %d in %s on line %d
diff --git a/ext/mysql/tests/mysql_field_name.phpt b/ext/mysql/tests/mysql_field_name.phpt
index c87ac188f7..85f6c42d93 100644
--- a/ext/mysql/tests/mysql_field_name.phpt
+++ b/ext/mysql/tests/mysql_field_name.phpt
@@ -46,6 +46,8 @@ print "done!";
require_once("clean_table.inc");
?>
--EXPECTF--
+Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
+
Warning: mysql_field_name() expects exactly 2 parameters, 1 given in %s on line %d
Warning: mysql_field_name(): Field -1 is invalid for MySQL result index %d in %s on line %d
diff --git a/ext/mysql/tests/mysql_field_seek.phpt b/ext/mysql/tests/mysql_field_seek.phpt
index 7e8b313c87..8487493a88 100644
--- a/ext/mysql/tests/mysql_field_seek.phpt
+++ b/ext/mysql/tests/mysql_field_seek.phpt
@@ -44,6 +44,8 @@ print "done!";
require_once("clean_table.inc");
?>
--EXPECTF--
+Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
+
Warning: mysql_field_seek(): Field -1 is invalid for MySQL result index %d in %s on line %d
bool(false)
object(stdClass)#%d (13) {
diff --git a/ext/mysql/tests/mysql_field_table.phpt b/ext/mysql/tests/mysql_field_table.phpt
index 707d1df987..826651a855 100644
--- a/ext/mysql/tests/mysql_field_table.phpt
+++ b/ext/mysql/tests/mysql_field_table.phpt
@@ -46,6 +46,8 @@ print "done!";
require_once("clean_table.inc");
?>
--EXPECTF--
+Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
+
Warning: mysql_field_table() expects exactly 2 parameters, 1 given in %s on line %d
Warning: mysql_field_table(): Field -1 is invalid for MySQL result index %d in %s on line %d
diff --git a/ext/mysql/tests/mysql_field_type.phpt b/ext/mysql/tests/mysql_field_type.phpt
index c737b4e3f2..c767cab6f1 100644
--- a/ext/mysql/tests/mysql_field_type.phpt
+++ b/ext/mysql/tests/mysql_field_type.phpt
@@ -46,6 +46,8 @@ print "done!";
require_once("clean_table.inc");
?>
--EXPECTF--
+Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
+
Warning: mysql_field_type() expects exactly 2 parameters, 1 given in %s on line %d
Warning: mysql_field_type(): Field -1 is invalid for MySQL result index %d in %s on line %d
diff --git a/ext/mysql/tests/mysql_free_result.phpt b/ext/mysql/tests/mysql_free_result.phpt
index fe132d8c2d..90498bd59a 100644
--- a/ext/mysql/tests/mysql_free_result.phpt
+++ b/ext/mysql/tests/mysql_free_result.phpt
@@ -44,6 +44,7 @@ print "done!";
require_once("clean_table.inc");
?>
--EXPECTF--
+Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
bool(true)
Warning: mysql_free_result(): %d is not a valid MySQL result resource in %s on line %d
diff --git a/ext/mysql/tests/mysql_get_host_info.phpt b/ext/mysql/tests/mysql_get_host_info.phpt
index 443910c319..4b21ddbb41 100644
--- a/ext/mysql/tests/mysql_get_host_info.phpt
+++ b/ext/mysql/tests/mysql_get_host_info.phpt
@@ -41,4 +41,5 @@ print "done!";
require_once("clean_table.inc");
?>
--EXPECTF--
+Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
done!
diff --git a/ext/mysql/tests/mysql_get_proto_info.phpt b/ext/mysql/tests/mysql_get_proto_info.phpt
index 043fb62043..3e1481121e 100644
--- a/ext/mysql/tests/mysql_get_proto_info.phpt
+++ b/ext/mysql/tests/mysql_get_proto_info.phpt
@@ -31,4 +31,5 @@ print "done!";
require_once("clean_table.inc");
?>
--EXPECTF--
+Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
done!
diff --git a/ext/mysql/tests/mysql_get_server_info.phpt b/ext/mysql/tests/mysql_get_server_info.phpt
index e806335e29..ad192e4722 100644
--- a/ext/mysql/tests/mysql_get_server_info.phpt
+++ b/ext/mysql/tests/mysql_get_server_info.phpt
@@ -36,4 +36,5 @@ if (NULL !== ($tmp = @mysql_get_server_info('too many', 'just too many')))
print "done!";
?>
--EXPECTF--
+Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
done!
diff --git a/ext/mysql/tests/mysql_info.phpt b/ext/mysql/tests/mysql_info.phpt
index 464578c8a5..c478679042 100644
--- a/ext/mysql/tests/mysql_info.phpt
+++ b/ext/mysql/tests/mysql_info.phpt
@@ -70,4 +70,5 @@ print "done!";
require_once("clean_table.inc");
?>
--EXPECTF--
-done! \ No newline at end of file
+Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
+done!
diff --git a/ext/mysql/tests/mysql_insert_id.phpt b/ext/mysql/tests/mysql_insert_id.phpt
index 460d9f3f4d..b69a96ae9b 100644
--- a/ext/mysql/tests/mysql_insert_id.phpt
+++ b/ext/mysql/tests/mysql_insert_id.phpt
@@ -66,6 +66,8 @@ print "done!";
require_once("clean_table.inc");
?>
--EXPECTF--
+Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
+
Warning: mysql_insert_id(): %d is not a valid MySQL-Link resource in %s on line %d
bool(false)
done!
diff --git a/ext/mysql/tests/mysql_list_dbs.phpt b/ext/mysql/tests/mysql_list_dbs.phpt
index 054e02ef98..402161aa63 100644
--- a/ext/mysql/tests/mysql_list_dbs.phpt
+++ b/ext/mysql/tests/mysql_list_dbs.phpt
@@ -51,4 +51,5 @@ print "done!\n";
require_once("clean_table.inc");
?>
--EXPECTF--
-done! \ No newline at end of file
+Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
+done!
diff --git a/ext/mysql/tests/mysql_list_fields.phpt b/ext/mysql/tests/mysql_list_fields.phpt
index e0b3fd5e39..259a94a399 100644
--- a/ext/mysql/tests/mysql_list_fields.phpt
+++ b/ext/mysql/tests/mysql_list_fields.phpt
@@ -64,6 +64,7 @@ if (!mysql_query("DROP TABLE IF EXISTS test2", $link))
mysql_close($link);
?>
--EXPECTF--
+Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
[006] [%d] %s
bool(false)
Field Offset 0
diff --git a/ext/mysql/tests/mysql_list_processes.phpt b/ext/mysql/tests/mysql_list_processes.phpt
index b0c71ad1b4..7838a6f98a 100644
--- a/ext/mysql/tests/mysql_list_processes.phpt
+++ b/ext/mysql/tests/mysql_list_processes.phpt
@@ -49,4 +49,5 @@ mysql_close($link);
print "done!\n";
?>
--EXPECTF--
-done! \ No newline at end of file
+Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
+done!
diff --git a/ext/mysql/tests/mysql_list_tables.phpt b/ext/mysql/tests/mysql_list_tables.phpt
index cf0b1a636d..3b753ae37a 100644
--- a/ext/mysql/tests/mysql_list_tables.phpt
+++ b/ext/mysql/tests/mysql_list_tables.phpt
@@ -82,4 +82,5 @@ print "done!\n";
require_once("clean_table.inc");
?>
--EXPECTF--
+Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
done!
diff --git a/ext/mysql/tests/mysql_max_links.phpt b/ext/mysql/tests/mysql_max_links.phpt
index 52ecd0ac08..32096c426e 100644
--- a/ext/mysql/tests/mysql_max_links.phpt
+++ b/ext/mysql/tests/mysql_max_links.phpt
@@ -54,9 +54,19 @@ mysql_close($links[1]);
print "done!\n";
?>
--EXPECTF--
+Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
+
+Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
+
+Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
+
Warning: mysql_connect(): Too many open links (2) in %s on line %s
[030] Cannot connect using host '%s', user '%s', password '****', [0] 0
+Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
+
+Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
+
Warning: mysql_connect(): Too many open links (2) in %s on line %s
[060] Cannot connect using host '%s', user '%s', password '****', [0] 0
array(3) {
@@ -67,4 +77,4 @@ array(3) {
[2]=>
bool(false)
}
-done! \ No newline at end of file
+done!
diff --git a/ext/mysql/tests/mysql_max_persistent.phpt b/ext/mysql/tests/mysql_max_persistent.phpt
index ac35cd178b..36f2266665 100644
--- a/ext/mysql/tests/mysql_max_persistent.phpt
+++ b/ext/mysql/tests/mysql_max_persistent.phpt
@@ -90,10 +90,16 @@ if (!$link = my_mysql_connect($host, $user, $passwd, $db, $port, $socket)) {
mysql_close($link);
?>
--EXPECTF--
+Deprecated: mysql_pconnect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
+
+Deprecated: mysql_pconnect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
+
Warning: mysql_pconnect(): Too many open persistent links (1) in %s on line %d
[020] Cannot connect using host '%s', user '%s', password '****', [0] 0
+
+Deprecated: mysql_pconnect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
array(1) {
[0]=>
resource(%d) of type (mysql link persistent)
}
-done! \ No newline at end of file
+done!
diff --git a/ext/mysql/tests/mysql_mysqlnd_read_timeout_long.phpt b/ext/mysql/tests/mysql_mysqlnd_read_timeout_long.phpt
index d54cb50708..2c67e64878 100644
--- a/ext/mysql/tests/mysql_mysqlnd_read_timeout_long.phpt
+++ b/ext/mysql/tests/mysql_mysqlnd_read_timeout_long.phpt
@@ -30,8 +30,9 @@ max_execution_time=12
print "done!";
?>
--EXPECTF--
+Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
array(1) {
[%u|b%"SLEEP(6)"]=>
%unicode|string%(1) "0"
}
-done! \ No newline at end of file
+done!
diff --git a/ext/mysql/tests/mysql_num_fields.phpt b/ext/mysql/tests/mysql_num_fields.phpt
index 0dad5f771d..4621dc91f8 100644
--- a/ext/mysql/tests/mysql_num_fields.phpt
+++ b/ext/mysql/tests/mysql_num_fields.phpt
@@ -52,5 +52,7 @@ print "done!";
require_once("clean_table.inc");
?>
--EXPECTF--
+Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
+
Warning: mysql_num_fields(): %d is not a valid MySQL result resource in %s on line %d
done!
diff --git a/ext/mysql/tests/mysql_num_rows.phpt b/ext/mysql/tests/mysql_num_rows.phpt
index 0f538c4a2b..5a803d41f9 100644
--- a/ext/mysql/tests/mysql_num_rows.phpt
+++ b/ext/mysql/tests/mysql_num_rows.phpt
@@ -79,6 +79,8 @@ print "done!";
require_once("clean_table.inc");
?>
--EXPECTF--
+Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
+
Warning: mysql_num_rows() expects parameter 1 to be resource, boolean given in %s on line %d
Warning: mysql_free_result() expects parameter 1 to be resource, boolean given in %s on line %d
diff --git a/ext/mysql/tests/mysql_pconn_disable.phpt b/ext/mysql/tests/mysql_pconn_disable.phpt
index 532e2e5788..6997e5970f 100644
--- a/ext/mysql/tests/mysql_pconn_disable.phpt
+++ b/ext/mysql/tests/mysql_pconn_disable.phpt
@@ -49,6 +49,13 @@ mysql.max_links=2
require_once("clean_table.inc");
?>
--EXPECTF--
+Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
+
+Deprecated: mysql_pconnect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
[001] Can connect to the server.
[002] Can fetch data using persistent connection! Data = '1'
-done! \ No newline at end of file
+
+Deprecated: mysql_pconnect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
+
+Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
+done!
diff --git a/ext/mysql/tests/mysql_pconn_kill.phpt b/ext/mysql/tests/mysql_pconn_kill.phpt
index efef421604..eb1feb7b85 100644
--- a/ext/mysql/tests/mysql_pconn_kill.phpt
+++ b/ext/mysql/tests/mysql_pconn_kill.phpt
@@ -106,5 +106,12 @@ mysql.max_persistent=2
require_once("clean_table.inc");
?>
--EXPECTF--
+Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
+
+Deprecated: mysql_pconnect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
bool(true)
+
+Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
+
+Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
done!
diff --git a/ext/mysql/tests/mysql_pconn_max_links.phpt b/ext/mysql/tests/mysql_pconn_max_links.phpt
index 3eca0e534a..ced94b3dbf 100644
--- a/ext/mysql/tests/mysql_pconn_max_links.phpt
+++ b/ext/mysql/tests/mysql_pconn_max_links.phpt
@@ -191,12 +191,17 @@ $host = substr($row['_user'], strrpos($row['_user'], "@") + 1, strlen($row['_use
mysql_close($link);
?>
--EXPECTF--
+Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
+
+Deprecated: mysql_pconnect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
array(2) {
[%u|b%"id"]=>
%unicode|string%(1) "1"
[%u|b%"label"]=>
%unicode|string%(1) "a"
}
+
+Deprecated: mysql_pconnect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
array(2) {
[%u|b%"id"]=>
%unicode|string%(1) "1"
diff --git a/ext/mysql/tests/mysql_pconn_reuse.phpt b/ext/mysql/tests/mysql_pconn_reuse.phpt
index ffa5f75f1b..26b4ca5f49 100644
--- a/ext/mysql/tests/mysql_pconn_reuse.phpt
+++ b/ext/mysql/tests/mysql_pconn_reuse.phpt
@@ -59,8 +59,17 @@ mysql.max_links=2
print "done!";
?>
--EXPECTF--
+Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
+
+Deprecated: mysql_pconnect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
[001] Can connect to the server.
[002] Can fetch data using persistent connection! Data = '1'
+Deprecated: mysql_pconnect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
+
+Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
+
+Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
+
Warning: mysql_connect(): Too many open links (2) in %s on line %d
-done! \ No newline at end of file
+done!
diff --git a/ext/mysql/tests/mysql_pconnect.phpt b/ext/mysql/tests/mysql_pconnect.phpt
index 5a7db93ab3..ec28d2ea8a 100644
--- a/ext/mysql/tests/mysql_pconnect.phpt
+++ b/ext/mysql/tests/mysql_pconnect.phpt
@@ -81,5 +81,17 @@ mysql.allow_persistent=1
print "done!";
?>
--EXPECTF--
+Deprecated: mysql_pconnect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
+
+Deprecated: mysql_pconnect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
+
Warning: mysql_pconnect(): Access denied for user '%s'@'%s' (using password: YES) in %s on line %d
+
+Deprecated: mysql_pconnect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
+
+Deprecated: mysql_pconnect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
+
+Deprecated: mysql_pconnect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
+
+Deprecated: mysql_pconnect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
done!
diff --git a/ext/mysql/tests/mysql_ping.phpt b/ext/mysql/tests/mysql_ping.phpt
index edf18c4391..0308df3396 100644
--- a/ext/mysql/tests/mysql_ping.phpt
+++ b/ext/mysql/tests/mysql_ping.phpt
@@ -42,6 +42,7 @@ print "done!";
require_once("clean_table.inc");
?>
--EXPECTF--
+Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
bool(true)
bool(true)
bool(true)
diff --git a/ext/mysql/tests/mysql_query.phpt b/ext/mysql/tests/mysql_query.phpt
index a5978a6c11..01b14ee284 100644
--- a/ext/mysql/tests/mysql_query.phpt
+++ b/ext/mysql/tests/mysql_query.phpt
@@ -113,6 +113,7 @@ if (!mysql_query('DROP TABLE IF EXISTS test', $link)) {
mysql_close($link);
?>
--EXPECTF--
+Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
array(1) {
[%u|b%"valid"]=>
%unicode|string%(30) "this is sql but with semicolon"
diff --git a/ext/mysql/tests/mysql_query_load_data_openbasedir.phpt b/ext/mysql/tests/mysql_query_load_data_openbasedir.phpt
index aa15f5ca12..c2cb41e026 100644
--- a/ext/mysql/tests/mysql_query_load_data_openbasedir.phpt
+++ b/ext/mysql/tests/mysql_query_load_data_openbasedir.phpt
@@ -111,6 +111,9 @@ unlink("./simple.csv");
print "done!";
?>
--EXPECTF--
+Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
+
+Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
[006] [1148] %s
[007] [0] ''
[008] LOAD DATA not run?
diff --git a/ext/mysql/tests/mysql_real_escape_string.phpt b/ext/mysql/tests/mysql_real_escape_string.phpt
index 2789ad276c..4fdedf7b37 100644
--- a/ext/mysql/tests/mysql_real_escape_string.phpt
+++ b/ext/mysql/tests/mysql_real_escape_string.phpt
@@ -33,6 +33,7 @@ assert($tmp === mysql_real_escape_string("foo" . chr(0) . "bar"));
print "done!";
?>
--EXPECTF--
+Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
%unicode|string%(31) "Am I a unicode string in PHP 6?"
%unicode|string%(2) "\\"
%unicode|string%(2) "\""
diff --git a/ext/mysql/tests/mysql_result.phpt b/ext/mysql/tests/mysql_result.phpt
index 2c7c618547..0a58b9b883 100644
--- a/ext/mysql/tests/mysql_result.phpt
+++ b/ext/mysql/tests/mysql_result.phpt
@@ -65,6 +65,8 @@ print "done!";
require_once("clean_table.inc");
?>
--EXPECTF--
+Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
+
Warning: mysql_result(): Unable to jump to row -1 on MySQL result index %d in %s on line %d
bool(false)
diff --git a/ext/mysql/tests/mysql_select_db.phpt b/ext/mysql/tests/mysql_select_db.phpt
index 211e34222e..e9bc99aa73 100644
--- a/ext/mysql/tests/mysql_select_db.phpt
+++ b/ext/mysql/tests/mysql_select_db.phpt
@@ -66,6 +66,7 @@ if (false !== ($tmp = mysql_select_db($db, $link)))
print "done!\n";
?>
--EXPECTF--
+Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
%unicode|string%(%d) "%s"
bool(false)
diff --git a/ext/mysql/tests/mysql_set_charset.phpt b/ext/mysql/tests/mysql_set_charset.phpt
index 953323b49c..a0bccd8c31 100644
--- a/ext/mysql/tests/mysql_set_charset.phpt
+++ b/ext/mysql/tests/mysql_set_charset.phpt
@@ -58,4 +58,5 @@ mysql_close($link);
print "done!";
?>
--EXPECTF--
+Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
done!
diff --git a/ext/mysql/tests/mysql_stat.phpt b/ext/mysql/tests/mysql_stat.phpt
index 30a840a2a1..d6a34df581 100644
--- a/ext/mysql/tests/mysql_stat.phpt
+++ b/ext/mysql/tests/mysql_stat.phpt
@@ -44,5 +44,7 @@ if (false !== ($tmp = mysql_stat($link)))
print "done!";
?>
--EXPECTF--
+Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
+
Warning: mysql_stat(): %d is not a valid MySQL-Link resource in %s on line %d
done!
diff --git a/ext/mysql/tests/mysql_tablename.phpt b/ext/mysql/tests/mysql_tablename.phpt
index 2415e4fda0..4bbe54d443 100644
--- a/ext/mysql/tests/mysql_tablename.phpt
+++ b/ext/mysql/tests/mysql_tablename.phpt
@@ -42,6 +42,8 @@ mysql_close($link);
print "done!";
?>
--EXPECTF--
+Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
+
Warning: mysql_tablename() expects at least 2 parameters, 1 given in %s on line %d
Warning: mysql_tablename(): Unable to jump to row -1 on MySQL result index %d in %s on line %d
diff --git a/ext/mysql/tests/mysql_thread_id.phpt b/ext/mysql/tests/mysql_thread_id.phpt
index b05bb3ed1c..aa95d31944 100644
--- a/ext/mysql/tests/mysql_thread_id.phpt
+++ b/ext/mysql/tests/mysql_thread_id.phpt
@@ -35,5 +35,7 @@ if (false !== ($tmp = mysql_thread_id($link)))
print "done!";
?>
--EXPECTF--
+Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
+
Warning: mysql_thread_id(): %d is not a valid MySQL-Link resource in %s on line %d
-done! \ No newline at end of file
+done!
diff --git a/ext/mysql/tests/mysql_trace_mode.phpt b/ext/mysql/tests/mysql_trace_mode.phpt
index 2b6c61d27b..7655975d70 100644
--- a/ext/mysql/tests/mysql_trace_mode.phpt
+++ b/ext/mysql/tests/mysql_trace_mode.phpt
@@ -29,6 +29,7 @@ print "done!\n";
require_once("clean_table.inc");
?>
--EXPECTF--
+Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
I don\'t mind character sets, do I?\n
Warning: mysql_query(): You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'BOGUS_SQL' at line 1 in %s on line %d
done!
diff --git a/ext/mysql/tests/mysql_unbuffered_query.phpt b/ext/mysql/tests/mysql_unbuffered_query.phpt
index ad9b4fbc52..8754b58b59 100644
--- a/ext/mysql/tests/mysql_unbuffered_query.phpt
+++ b/ext/mysql/tests/mysql_unbuffered_query.phpt
@@ -107,6 +107,7 @@ if (!mysql_query('DROP TABLE IF EXISTS test', $link)) {
mysql_close($link);
?>
--EXPECTF--
+Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d
array(1) {
[%u|b%"valid"]=>
%unicode|string%(30) "this is sql but with semicolon"