Author: uwendel
Date: 2007-07-06 17:55:55 +0200 (Fri, 06 Jul 2007)
New Revision: 669
Modified:
trunk/tests/ext/mysqli/mysqli_fetch_assoc_no_alias_utf8.phpt
Log:
Adding additional test if UCS2 is available. I hope lady Kate did not bork the encoding.
Modified: trunk/tests/ext/mysqli/mysqli_fetch_assoc_no_alias_utf8.phpt
===================================================================
--- trunk/tests/ext/mysqli/mysqli_fetch_assoc_no_alias_utf8.phpt 2007-07-06 15:34:57 UTC
(rev 668)
+++ trunk/tests/ext/mysqli/mysqli_fetch_assoc_no_alias_utf8.phpt 2007-07-06 15:55:55 UTC
(rev 669)
@@ -5,20 +5,31 @@
require_once('skipif.inc');
require_once('skipifemb.inc');
require('connect.inc');
-
+
if (!$link = mysqli_connect($host, $user, $passwd, $db, $port, $socket))
die("skip Cannot connect to server to check charsets");
if (!$res = mysqli_query($link, "SHOW CHARACTER SET LIKE 'UTF8'"))
die("skip Cannot run SHOW CHARACTER SET to check charsets");
-
+
if (!$tmp = mysqli_fetch_assoc($res))
die("skip Looks like UTF8 is not available on the server");
-
+
if (strtolower($tmp['Charset']) !== 'utf8')
die("skip Not sure if UTF8 is available, cancelling the test");
-
+
mysqli_free_result($res);
+
+ if (!$res = mysqli_query($link, "SHOW CHARACTER SET LIKE 'UCS2'"))
+ die("skip Cannot run SHOW CHARACTER SET to check charsets");
+
+ if (!$tmp = mysqli_fetch_assoc($res))
+ die("skip Looks like UCS2 is not available on the server");
+
+ if (strtolower($tmp['Charset']) !== 'ucs2')
+ die("skip Not sure if UCS2 is available, cancelling the test");
+
+ mysqli_free_result($res);
mysqli_close($link);
?>
<?php require_once('skipifemb.inc'); ?>
| Thread |
|---|
| • PHP mysqlnd svn commit: r669 - trunk/tests/ext/mysqli | uwendel | 6 Jul |