cellog          Mon Oct 13 04:50:37 2008 UTC

  Modified files:              (Branch: PHP_5_3)
    /php-src/ext/phar/tests     stat.phpt 
  Log:
  increase code coverage
  
http://cvs.php.net/viewvc.cgi/php-src/ext/phar/tests/stat.phpt?r1=1.3&r2=1.3.2.1&diff_format=u
Index: php-src/ext/phar/tests/stat.phpt
diff -u php-src/ext/phar/tests/stat.phpt:1.3 
php-src/ext/phar/tests/stat.phpt:1.3.2.1
--- php-src/ext/phar/tests/stat.phpt:1.3        Sun May 11 19:17:50 2008
+++ php-src/ext/phar/tests/stat.phpt    Mon Oct 13 04:50:37 2008
@@ -14,7 +14,7 @@
 $fname2 = dirname(__FILE__) . '/' . basename(__FILE__, '.php') . '.tar';
 $fname3 = dirname(__FILE__) . '/' . basename(__FILE__, '.php') . '.phar.tar';
 $a = new Phar($fname);
-$a['index.php'] = '<?php
+$a['my/index.php'] = '<?php
 echo "stat\n";
 var_dump(stat("dir/file1.txt"));
 echo "lstat\n";
@@ -53,13 +53,17 @@
 var_dump(is_file("dir/file1.txt"));
 echo "is_link\n";
 var_dump(is_link("dir/file1.txt"));
+echo "not found\n";
+var_dump(file_exists("not/found"));
+echo "not found 2\n";
+var_dump(fileperms("not/found"));
 ?>';
 $a['dir/file1.txt'] = 'hi';
 $a['dir/file2.txt'] = 'hi2';
 $a['dir/file3.txt'] = 'hi3';
 $a->setStub('<?php
 set_include_path("phar://" . __FILE__ . "/dir" . PATH_SEPARATOR . "phar://" . 
__FILE__);
-include "index.php";
+include "my/index.php";
 __HALT_COMPILER();');
 include $fname;
 ?>
@@ -212,4 +216,10 @@
 bool(true)
 is_link
 bool(false)
+not found
+bool(false)
+not found 2
+
+Warning: fileperms(): stat failed for not/found in 
phar://%sstat.phar.php/my/index.php on line %d
+bool(false)
 ===DONE===
\ No newline at end of file



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

Reply via email to