From abdc3cd03ec77fa3ce3978fed9c590a8ccb5eb65 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Rapha=C3=ABl=20Gertz?= Date: Tue, 27 Feb 2024 11:50:09 +0100 Subject: [PATCH] Update phpunit binary --- bin/phpunit | 24 +++++++++++++++++------- 1 file changed, 17 insertions(+), 7 deletions(-) mode change 100644 => 100755 bin/phpunit diff --git a/bin/phpunit b/bin/phpunit old mode 100644 new mode 100755 index 4d1ed05..692bacc --- a/bin/phpunit +++ b/bin/phpunit @@ -1,13 +1,23 @@ #!/usr/bin/env php = 80000) { + require dirname(__DIR__).'/vendor/phpunit/phpunit/phpunit'; + } else { + define('PHPUNIT_COMPOSER_INSTALL', dirname(__DIR__).'/vendor/autoload.php'); + require PHPUNIT_COMPOSER_INSTALL; + PHPUnit\TextUI\Command::main(); + } +} else { + if (!is_file(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); + } -require dirname(__DIR__).'/vendor/symfony/phpunit-bridge/bin/simple-phpunit.php'; + require dirname(__DIR__).'/vendor/symfony/phpunit-bridge/bin/simple-phpunit.php'; +} -- 2.41.1