mirror of
https://github.com/Part-DB/Part-DB-server.git
synced 2025-06-30 05:24:28 +02:00
Made tests compatible with phpunit 8
The new simple-phpunit wrapper is selects the best phpunit version automatically and removes all the void return types if needed.
This commit is contained in:
parent
a62f947b86
commit
6405dee0ac
19 changed files with 19 additions and 37 deletions
15
bin/phpunit
15
bin/phpunit
|
@ -1,19 +1,10 @@
|
|||
#!/usr/bin/env php
|
||||
<?php
|
||||
|
||||
if (!file_exists(dirname(__DIR__).'/vendor/symfony/phpunit-bridge/bin/simple-phpunit')) {
|
||||
echo "Unable to find the `simple-phpunit` script in `vendor/symfony/phpunit-bridge/bin/`.\n";
|
||||
if (!file_exists(dirname(__DIR__).'/vendor/symfony/phpunit-bridge/bin/simple-phpunit.php')) {
|
||||
echo "Unable to find the `simple-phpunit.php` script in `vendor/symfony/phpunit-bridge/bin/`.\n";
|
||||
exit(1);
|
||||
}
|
||||
|
||||
if (false === getenv('SYMFONY_PHPUNIT_VERSION')) {
|
||||
putenv('SYMFONY_PHPUNIT_VERSION=7.5');
|
||||
}
|
||||
if (false === getenv('SYMFONY_PHPUNIT_REMOVE')) {
|
||||
putenv('SYMFONY_PHPUNIT_REMOVE=');
|
||||
}
|
||||
if (false === getenv('SYMFONY_PHPUNIT_DIR')) {
|
||||
putenv('SYMFONY_PHPUNIT_DIR='.__DIR__.'/.phpunit');
|
||||
}
|
||||
|
||||
require dirname(__DIR__).'/vendor/symfony/phpunit-bridge/bin/simple-phpunit';
|
||||
require dirname(__DIR__).'/vendor/symfony/phpunit-bridge/bin/simple-phpunit.php';
|
Loading…
Add table
Add a link
Reference in a new issue