This repository was archived by the owner on Jun 2, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 47
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Updated readme, added phpunit5 phar for testing purposes.
- Loading branch information
1 parent
ed97845
commit 7be6b09
Showing
2 changed files
with
56 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,52 @@ | ||
#!/usr/bin/env php | ||
<?php | ||
/* | ||
* This file is part of PHPUnit. | ||
* | ||
* (c) Sebastian Bergmann <[email protected]> | ||
* | ||
* For the full copyright and license information, please view the LICENSE | ||
* file that was distributed with this source code. | ||
*/ | ||
|
||
if (version_compare('5.6.0', PHP_VERSION, '>')) { | ||
fwrite( | ||
STDERR, | ||
sprintf( | ||
'This version of PHPUnit is supported on PHP 5.6 and PHP 7.0.' . PHP_EOL . | ||
'You are using PHP %s (%s).' . PHP_EOL, | ||
PHP_VERSION, | ||
PHP_BINARY | ||
) | ||
); | ||
|
||
die(1); | ||
} | ||
|
||
if (!ini_get('date.timezone')) { | ||
ini_set('date.timezone', 'UTC'); | ||
} | ||
|
||
foreach (array(__DIR__ . '/../../autoload.php', __DIR__ . '/../vendor/autoload.php', __DIR__ . '/vendor/autoload.php') as $file) { | ||
if (file_exists($file)) { | ||
define('PHPUNIT_COMPOSER_INSTALL', $file); | ||
|
||
break; | ||
} | ||
} | ||
|
||
unset($file); | ||
|
||
if (!defined('PHPUNIT_COMPOSER_INSTALL')) { | ||
fwrite(STDERR, | ||
'You need to set up the project dependencies using the following commands:' . PHP_EOL . | ||
'wget http://getcomposer.org/composer.phar' . PHP_EOL . | ||
'php composer.phar install' . PHP_EOL | ||
); | ||
|
||
die(1); | ||
} | ||
|
||
require PHPUNIT_COMPOSER_INSTALL; | ||
|
||
PHPUnit_TextUI_Command::main(); |