List:Commits« Previous MessageNext Message »
From:uwendel Date:June 19 2007 9:51am
Subject:PHP mysqlnd svn commit: r395 - trunk/tests/ext/mysqli
View as plain text  
Author: uwendel
Date: 2007-06-19 11:51:15 +0200 (Tue, 19 Jun 2007)
New Revision: 395

Modified:
   trunk/tests/ext/mysqli/mysqli_report.phpt
Log:
Trying to provoke a situation that triggers reporiting of an inproper/missing index. As
this is MySQL version dependent, we will most likely never get 
mysqli_report.c beyond 50% code coverage. 


Modified: trunk/tests/ext/mysqli/mysqli_report.phpt
===================================================================
--- trunk/tests/ext/mysqli/mysqli_report.phpt	2007-06-19 09:49:23 UTC (rev 394)
+++ trunk/tests/ext/mysqli/mysqli_report.phpt	2007-06-19 09:51:15 UTC (rev 395)
@@ -181,7 +181,7 @@
       - query must cause the warning on all MySQL versions
       
     TODO:
-        
+    */    
     $log_slow_queries = false;
     $log_queries_not_using_indexes = false;
     
@@ -206,17 +206,21 @@
     
     if ($log_slow_queries && $log_queries_not_using_indexes) {
         
-        for ($i = 100; $i < 200; $i++) {
+        for ($i = 100; $i < 20000; $i++) {
             if (!mysqli_query($link, "INSERT INTO test(id, label) VALUES ($i, 'z')"))
                 printf("[022 - %d] [%d] %s\n", $i - 99, mysqli_errno($link),
mysqli_error($link)); 
         }
         
+        if (!$res = @mysqli_query($link, "SELECT id, label FROM test WHERE id = 1323"))
+           printf("[023] [%d] %s\n", mysqli_errno($link), mysqli_error($link)); 
+           
+        mysqli_free_result($res);
+        
         mysqli_report(MYSQLI_REPORT_OFF);
         mysqli_report(MYSQLI_REPORT_INDEX);     
         
         
-    }
-    */
+    }  
     
     print "done!";
 ?>

Thread
PHP mysqlnd svn commit: r395 - trunk/tests/ext/mysqliuwendel19 Jun