Skip to content

Commit 8fa1a31

Browse files
author
Greg Beaver
committed
MFB fix to test
1 parent 0a4d447 commit 8fa1a31

File tree

1 file changed

+11
-2
lines changed

1 file changed

+11
-2
lines changed

ext/phar/tests/phar_create_in_cwd.phpt

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,6 @@ chdir(dirname(__FILE__));
1111
try {
1212
$p = new Phar('brandnewphar.phar');
1313
$p['file1.txt'] = 'hi';
14-
$p->commit();
1514
var_dump($p->getStub());
1615
$p->setStub("<?php
1716
function __autoload(\$class)
@@ -33,5 +32,15 @@ __HALT_COMPILER();
3332
unlink(dirname(__FILE__) . '/brandnewphar.phar');
3433
?>
3534
--EXPECT--
36-
RecursiveDirectoryIterator::__construct(phar://brandnewphar.phar): failed to open dir: phar error: no directory in "phar://brandnewphar.phar", must have at least phar://brandnewphar.phar/ for root directory (always use full path to a new phar)
35+
string(29) "<?php __HALT_COMPILER(); ?>
36+
"
37+
string(200) "<?php
38+
function __autoload($class)
39+
{
40+
include 'phar://' . str_replace('_', '/', $class);
41+
}
42+
Phar::mapPhar('brandnewphar.phar');
43+
include 'phar://brandnewphar.phar/startup.php';
44+
__HALT_COMPILER(); ?>
45+
"
3746
===DONE===

0 commit comments

Comments
 (0)