--TEST-- Phar: bzipped phar --SKIPIF-- --INI-- phar.readonly=0 phar.require_hash=0 --FILE-- setAlias('another'); $b = new Phar($fname2); var_dump($b->isFileFormat(Phar::PHAR)); var_dump($b->isCompressed() == Phar::BZ2); // additional code coverage $b->isFileFormat(array()); try { $b->isFileFormat(25); } catch (Exception $e) { echo $e->getMessage(),"\n"; } ?> ===DONE=== --CLEAN-- --EXPECTF-- string(9) "it worked" string(%d) "phar://%sphar_bz2.phar/tar_004.php" bool(true) bool(true) Warning: Phar::isFileFormat() expects parameter 1 to be int, array given in %sphar_bz2.php on line %d Unknown file format specified ===DONE===