--TEST-- Phar::compressFiles(Phar::BZ2) zip format --SKIPIF-- --INI-- phar.readonly=0 --FILE-- isCompressed()); var_dump(file_get_contents($pname . '/b')); var_dump($phar['b']->isCompressed()); var_dump(file_get_contents($pname . '/c')); var_dump($phar['c']->isCompressed()); $phar->compressFiles(Phar::BZ2); var_dump(file_get_contents($pname . '/a')); var_dump($phar['a']->isCompressed(Phar::GZ)); var_dump($phar['a']->isCompressed(Phar::BZ2)); var_dump(file_get_contents($pname . '/b')); var_dump($phar['b']->isCompressed(Phar::GZ)); var_dump($phar['b']->isCompressed(Phar::BZ2)); var_dump(file_get_contents($pname . '/c')); var_dump($phar['c']->isCompressed(Phar::GZ)); var_dump($phar['b']->isCompressed(Phar::BZ2)); $phar['d'] = 'hi'; // increases code coverage by having ufp open copy($fname, $fname2); $c = new Phar($fname2); var_dump(file_get_contents($pname2 . '/a')); var_dump($c['a']->isCompressed(Phar::GZ)); var_dump($c['a']->isCompressed(Phar::BZ2)); ?> --CLEAN-- --EXPECT-- string(1) "a" bool(false) string(1) "b" bool(false) string(1) "c" bool(false) string(1) "a" bool(false) bool(true) string(1) "b" bool(false) bool(true) string(1) "c" bool(false) bool(true) string(1) "a" bool(false) bool(true)