Re: cvs: pecl /phar makestub.php phar.c phar_internal.h phar_object.c shortarc.php stub.h /phar/tests nophar.phar nophar.phar.inc nophar_web.phpt
phar_commitwrite.phpt phar_create_in_cwd.phpt phar_createdefaultstub.phpt withphar_web.phpt
| From: | Steph Fox | Date: | Sun, 20 Jan 2008 02:43:05 +0000 |
| Subject: | Re: cvs: pecl /phar makestub.php phar.c phar_internal.h phar_object.c shortarc.php stub.h /phar/tests nophar.phar nophar.phar.inc nophar_web.phpt phar_commitwrite.phpt phar_create_in_cwd.phpt phar_createdefaultstub.phpt withphar_web.phpt |
||
| References: | 1 | Groups: | php.pecl.cvs |
| Request: | Send a blank email to pecl-cvs+get-9570@lists.php.net to get a copy of this message | ||
Hi Greg,
Number of tests : 273 261Tests skipped : 12 ( 4.4%) --------
Tests warned : 0 ( 0.0%) ( 0.0%) Tests failed : 3 ( 1.1%) ( 1.1%) Tests passed : 258 ( 94.5%) ( 98.9%)---------------------------------------------------------------------
Time taken : 120 seconds===================================================================== ===================================================================== FAILED TEST SUMMARY --------------------------------------------------------------------- Phar: include and parser error [C:\sandbox\pecl\phar\tests\031.phpt] Phar with phar meta-data (write) [C:\sandbox\pecl\phar\tests\phar_metadata_write.phpt] Phar and RecursiveDirectoryIterator [C:\sandbox\pecl\phar\tests\phar_oo_005.phpt] ===================================================================== The attached patch fixes all three tests, but the last two probably shouldn't be fixed - they may be indicative of a genuine bug somewhere. There's no exception message if a try/catch block is inserted, but I get 'Fatal error: Ignoring exception from PharFileInfo::__destruct() while an exception is already active (Uncaught UnexpectedValueException in ...' without it. The RecursiveDirectoryIterator test just fails without error without a try/catch block, but passes if there is one. Something odd going on. - Steph ----- Original Message ----- From: "Greg Beaver" <cellog@php.net> To: <pecl-cvs@lists.php.net> Sent: Sunday, January 20, 2008 12:49 AM Subject: [PECL-CVS] cvs: pecl /phar makestub.php phar.c phar_internal.h phar_object.c shortarc.php stub.h /phar/tests nophar.phar nophar.phar.inc nophar_web.phpt phar_commitwrite.phpt phar_create_in_cwd.phpt phar_createdefaultstub.phpt withphar_web.phpt
cellog Sun Jan 20 00:49:44 2008 UTC Added files: /pecl/phar/tests nophar_web.phpt withphar_web.phpt Modified files: /pecl/phar makestub.php phar.c phar_internal.h phar_object.c--------------------------------------------------------------------------------shortarc.php stub.h/pecl/phar/tests nophar.phar nophar.phar.inc phar_commitwrite.phptphar_create_in_cwd.phpt phar_createdefaultstub.phptLog: add web-based support for default stub, now phars written with webPhar() will work out of the box regardless of server configuration with phar file format split up stub.h strings into 2046 byte chunks because MS VC 6 is friggin stupid
-- PECL CVS Mailing List To unsubscribe, visit: http://www.php.net/unsub.php
Index: tests/031.phpt =================================================================== RCS file: /repository/pecl/phar/tests/031.phpt,v retrieving revision 1.7 diff -u -r1.7 031.phpt --- tests/031.phpt 4 Jan 2008 16:26:42 -0000 1.7 +++ tests/031.phpt 20 Jan 2008 02:21:51 -0000 @@ -28,4 +28,4 @@ --EXPECTF-- string(25) "<?php echo new new class;" -Parse error: %s error%s in phar://%sphar_oo_test.phar.php/a.php on line %d +Parse error: %s phar://%sphar_oo_test.phar.php/a.php on line %d Index: tests/phar_metadata_write.phpt =================================================================== RCS file: /repository/pecl/phar/tests/phar_metadata_write.phpt,v retrieving revision 1.2 diff -u -r1.2 phar_metadata_write.phpt --- tests/phar_metadata_write.phpt 4 Jan 2008 16:26:43 -0000 1.2 +++ tests/phar_metadata_write.phpt 20 Jan 2008 02:36:00 -0000 @@ -36,9 +36,14 @@ unset($phar); -foreach($files as $name => $cont) { - var_dump(file_get_contents($pname.'/'.$name)); +try { + foreach($files as $name => $cont) { + var_dump(file_get_contents($pname.'/'.$name)); + } +} catch (UnexpectedValueException $e) { + print $e->getMessage(); } + ?> ===DONE=== --CLEAN-- Index: tests/phar_oo_005.phpt =================================================================== RCS file: /repository/pecl/phar/tests/phar_oo_005.phpt,v retrieving revision 1.7 diff -u -r1.7 phar_oo_005.phpt --- tests/phar_oo_005.phpt 4 Jan 2008 16:26:43 -0000 1.7 +++ tests/phar_oo_005.phpt 20 Jan 2008 02:40:53 -0000 @@ -14,14 +14,18 @@ $it = new RecursiveDirectoryIterator('phar://'.$fname); $it = new RecursiveIteratorIterator($it); -foreach($it as $name => $ent) -{ - var_dump(str_replace(array('\\', $fname), array('/', '*'), $name)); - var_dump(str_replace(array('\\', $fname), array('/', '*'), $ent->getPathname())); - var_dump(str_replace('\\', '/', $it->getSubPath())); - var_dump(str_replace('\\', '/', $it->getSubPathName())); - $sub = $it->getPathInfo(); - var_dump(str_replace('\\', '/', $sub->getFilename())); +try { + foreach($it as $name => $ent) + { + var_dump(str_replace(array('\\', $fname), array('/', '*'), $name)); + var_dump(str_replace(array('\\', $fname), array('/', '*'), $ent->getPathname())); + var_dump(str_replace('\\', '/', $it->getSubPath())); + var_dump(str_replace('\\', '/', $it->getSubPathName())); + $sub = $it->getPathInfo(); + var_dump(str_replace('\\', '/', $sub->getFilename())); + } +} catch (Exception $e) { + print $e->getMessage(); } ?>