Skip to content

Commit 41f7e06

Browse files
committed
meh
1 parent 15395ea commit 41f7e06

3 files changed

Lines changed: 22 additions & 3 deletions

File tree

Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ CHURN = tools/churn/vendor/bin/churn
1111
INFECTION = tools/infection/vendor/bin/infection
1212
PHP_CS_FIXER = tools/php-cs-fixer/vendor/bin/php-cs-fixer
1313
PHPACTOR = tools/phpactor/vendor/bin/phpactor
14-
PHPUNIT = tools/phpunit/vendor/bin/phpunit
14+
PHPUNIT = tools/phpunit/bin/run
1515
PSALM = tools/psalm/vendor/bin/psalm
1616
RECTOR = tools/rector/vendor/bin/rector
1717
# end: Tools

composer.json

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -230,7 +230,6 @@
230230
}
231231
},
232232
"require-dev": {
233-
"phpunit/phpunit": "^10.4",
234233
"symfony/http-foundation": "^5 || ^6 || ^7",
235234
"symfony/messenger": "^5 || ^6 || ^7",
236235
"symfony/serializer": "^5 || ^6 || ^7"
@@ -246,4 +245,4 @@
246245
"@php -r \"if(file_exists('./.git')&&file_exists('./build/hooks/pre-commit')){copy('./build/hooks/pre-commit','./.git/hooks/pre-commit');chmod('./.git/hooks/pre-commit',0755);}\""
247246
]
248247
}
249-
}
248+
}

tools/phpunit/bin/run

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
#!/usr/bin/env php
2+
<?php
3+
declare(strict_types=1);
4+
5+
// Ensure we use the PHPUnit installed under tools/phpunit first
6+
require __DIR__ . '/../vendor/autoload.php';
7+
8+
// Then load the project autoload so tests and source classes are available
9+
// This may also provide a root-level phpunit, but classes are already loaded.
10+
$projectAutoload = getcwd() . '/vendor/autoload.php';
11+
if (file_exists($projectAutoload)) {
12+
require $projectAutoload;
13+
}
14+
15+
// Forward all CLI args to PHPUnit's Application
16+
$argv = $_SERVER['argv'] ?? [];
17+
18+
$app = new PHPUnit\TextUI\Application();
19+
exit($app->run($argv));
20+

0 commit comments

Comments
 (0)