indeyets                Fri Jul  4 14:30:36 2008 UTC

  Modified files:              (Branch: PHP_5_3)
    /php-src/ext/posix/tests    posix_strerror_error.phpt 
                                posix_strerror_variation1.phpt 
  Log:
  fixed tests not to rely on actual strings of errors, as those are not defined 
by any standard and are platform-dependent
  
  
http://cvs.php.net/viewvc.cgi/php-src/ext/posix/tests/posix_strerror_error.phpt?r1=1.1.4.3&r2=1.1.4.4&diff_format=u
Index: php-src/ext/posix/tests/posix_strerror_error.phpt
diff -u php-src/ext/posix/tests/posix_strerror_error.phpt:1.1.4.3 
php-src/ext/posix/tests/posix_strerror_error.phpt:1.1.4.4
--- php-src/ext/posix/tests/posix_strerror_error.phpt:1.1.4.3   Fri Apr 11 
11:05:56 2008
+++ php-src/ext/posix/tests/posix_strerror_error.phpt   Fri Jul  4 14:30:36 2008
@@ -24,7 +24,7 @@
 
 echo "\n-- Testing posix_strerror() function with invalid error number --\n";
 $errno = -999;
-var_dump( posix_strerror($errno) );
+echo gettype( posix_strerror($errno) )."\n";
 
 echo "Done";
 ?>
@@ -42,5 +42,5 @@
 bool(false)
 
 -- Testing posix_strerror() function with invalid error number --
-string(%d) "Unknown error %d"
+string
 Done
http://cvs.php.net/viewvc.cgi/php-src/ext/posix/tests/posix_strerror_variation1.phpt?r1=1.1.4.3&r2=1.1.4.4&diff_format=u
Index: php-src/ext/posix/tests/posix_strerror_variation1.phpt
diff -u php-src/ext/posix/tests/posix_strerror_variation1.phpt:1.1.4.3 
php-src/ext/posix/tests/posix_strerror_variation1.phpt:1.1.4.4
--- php-src/ext/posix/tests/posix_strerror_variation1.phpt:1.1.4.3      Fri Apr 
11 11:05:56 2008
+++ php-src/ext/posix/tests/posix_strerror_variation1.phpt      Fri Jul  4 
14:30:36 2008
@@ -73,7 +73,7 @@
 
 foreach($values as $value) {
       echo "\nArg value $value \n";
-      var_dump( posix_strerror($value) );
+      echo gettype( posix_strerror($value) )."\n";
 };
 
 echo "Done";
@@ -86,87 +86,87 @@
 Notice: Undefined variable: unset_var in %s on line %d
 
 Arg value 10.5 
-string(18) "No child processes"
+string
 
 Arg value -10.5 
-string(%d) "Unknown error %d"
+string
 
 Arg value 101234567000 
-string(%d) "Unknown error %d"
+string
 
 Arg value 1.07654321E-9 
-string(7) "Success"
+string
 
 Arg value 0.5 
-string(7) "Success"
+string
 
 Arg value Array 
 
 Warning: posix_strerror() expects parameter 1 to be long, array given in %s on 
line %d
-bool(false)
+boolean
 
 Arg value Array 
 
 Warning: posix_strerror() expects parameter 1 to be long, array given in %s on 
line %d
-bool(false)
+boolean
 
 Arg value Array 
 
 Warning: posix_strerror() expects parameter 1 to be long, array given in %s on 
line %d
-bool(false)
+boolean
 
 Arg value Array 
 
 Warning: posix_strerror() expects parameter 1 to be long, array given in %s on 
line %d
-bool(false)
+boolean
 
 Arg value Array 
 
 Warning: posix_strerror() expects parameter 1 to be long, array given in %s on 
line %d
-bool(false)
+boolean
 
 Arg value  
-string(7) "Success"
+string
 
 Arg value  
-string(7) "Success"
+string
 
 Arg value 1 
-string(23) "Operation not permitted"
+string
 
 Arg value  
-string(7) "Success"
+string
 
 Arg value 1 
-string(23) "Operation not permitted"
+string
 
 Arg value  
-string(7) "Success"
+string
 
 Arg value  
 
 Warning: posix_strerror() expects parameter 1 to be long, string given in %s 
on line %d
-bool(false)
+boolean
 
 Arg value  
 
 Warning: posix_strerror() expects parameter 1 to be long, string given in %s 
on line %d
-bool(false)
+boolean
 
 Arg value string 
 
 Warning: posix_strerror() expects parameter 1 to be long, string given in %s 
on line %d
-bool(false)
+boolean
 
 Arg value string 
 
 Warning: posix_strerror() expects parameter 1 to be long, string given in %s 
on line %d
-bool(false)
+boolean
 
 Arg value  
-string(7) "Success"
+string
 
 Arg value  
-string(7) "Success"
+string
 
 Catchable fatal error: Object of class stdClass could not be converted to 
string in %s on line %d



-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to