Skip to content

Commit

Permalink
Closes #1926
Browse files Browse the repository at this point in the history
  • Loading branch information
sebastianbergmann committed Aug 19, 2016
1 parent 7e48a0b commit 5e6595f
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 13 deletions.
1 change: 1 addition & 0 deletions ChangeLog-6.0.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ All notable changes of the PHPUnit 6.0 release series are documented in this fil
* `setUpBeforeClass()` is now invoked after all methods annotated with `@beforeClass`
* `setUp()` is now invoked after all methods annotated with `@before`
* Added `addWarning()` method to `PHPUnit\Framework\TestListener` interface
* The binary PHAR is now binary-only and cannot be used as a library anymore

### Removed

Expand Down
18 changes: 5 additions & 13 deletions build/binary-phar-autoload.php.in
Original file line number Diff line number Diff line change
Expand Up @@ -9,26 +9,18 @@ if (PHP_MAJOR_VERSION < 7) {
die(1);
}

if (__FILE__ == realpath($GLOBALS['_SERVER']['SCRIPT_NAME'])) {
$execute = true;
} else {
$execute = false;
}

define('__PHPUNIT_PHAR__', str_replace(DIRECTORY_SEPARATOR, '/', __FILE__));
define('__PHPUNIT_PHAR_ROOT__', 'phar://___PHAR___');

Phar::mapPhar('___PHAR___');

___FILELIST___

if ($execute) {
if (isset($_SERVER['argv'][1]) && $_SERVER['argv'][1] == '--manifest') {
print file_get_contents(__PHPUNIT_PHAR_ROOT__ . '/manifest.txt');
exit;
}

PHPUnit_TextUI_Command::main();
if (isset($_SERVER['argv'][1]) && $_SERVER['argv'][1] == '--manifest') {
print file_get_contents(__PHPUNIT_PHAR_ROOT__ . '/manifest.txt');
exit;
}

PHPUnit_TextUI_Command::main();

__HALT_COMPILER();

0 comments on commit 5e6595f

Please sign in to comment.