Skip to content

Commit

Permalink
Merge branch '1.2' into 1
Browse files Browse the repository at this point in the history
  • Loading branch information
github-actions[bot] committed Sep 11, 2024
2 parents dfe559e + 57469f7 commit 0abc149
Showing 1 changed file with 15 additions and 1 deletion.
16 changes: 15 additions & 1 deletion action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,21 @@ runs:
env:
PHPUNIT_SUITE: ${{ inputs.phpunit_suite }}
run: |
PHPUNIT_OPTIONS="--verbose --colors=always"
PHPUNIT_OPTIONS="--colors=always"
[[ $(vendor/bin/phpunit --version) =~ ([0-9]+)\.([0-9]+)\.([0-9]+) ]]
MAJOR=${BASH_REMATCH[1]}
MINOR=${BASH_REMATCH[2]}
PATCH=${BASH_REMATCH[3]}
INT_VERSION=$(( $MAJOR * 10000 + $MINOR * 100 + $PATCH ))
if (( "$INT_VERSION" < 100000 )); then
# --verbose option removed in PHPUnit 10, as it's now always verbose
PHPUNIT_OPTIONS="$PHPUNIT_OPTIONS --verbose"
fi
# --display-phpunit-deprecations option added in PHPUnit 11.3.3
# deprecations will display by default in PHPUnit <= 11.3.2
if (( "$INT_VERSION" >= 110303 )); then
PHPUNIT_OPTIONS="$PHPUNIT_OPTIONS --display-phpunit-deprecations"
fi
if [[ "$PHPUNIT_SUITE" != "all" ]] && [[ "$PHPUNIT_SUITE" != "" ]]; then
PHPUNIT_OPTIONS="$PHPUNIT_OPTIONS --testsuite "$PHPUNIT_SUITE""
fi
Expand Down

0 comments on commit 0abc149

Please sign in to comment.