1
0
Fork 0
mirror of https://codeberg.org/icewind/haze.git synced 2026-08-02 12:14:46 +02:00

make it easier to use a specific phpunit version

This commit is contained in:
Robin Appelman 2026-07-14 00:48:56 +02:00
commit d59b99211a
5 changed files with 27 additions and 12 deletions

View file

@ -3,5 +3,15 @@
def --wrapped main [...rest] {
cd $env.WEBROOT
XDEBUG_SESSION=haze phpunit --configuration $"($env.WEBROOT)/tests/phpunit-autotest.xml" ...$rest
mut args = $rest;
mut command = "phpunit";
if (($args | first | detect type | describe) == "int") {
let phpunit_version = $rest | first
$command = $"phpunit($phpunit_version)"
$args = $args | skip 1
}
let command = $command
let args = $args
XDEBUG_SESSION=haze exec $command --configuration $"($env.WEBROOT)/tests/phpunit-autotest.xml" ...$args
}