Skip to content

Commit

Permalink
CI - add php 8.0, temporarily run just phpunit
Browse files Browse the repository at this point in the history
https://github.com/EdgedesignCZ/phpqa/runs/1813595507?check_suite_focus=true#step:4:8
Your lock file does not contain a compatible set of packages.

https://github.com/EdgedesignCZ/phpqa/pull/219/checks?check_run_id=1821132375#step:5:38
Your requirements could not be resolved to an installable set of packages.

https://github.com/EdgedesignCZ/phpqa/runs/1821200517?check_suite_focus=true#step:5:136
hamcrest/hamcrest-php v2.0.0 requires php ^5.3|^7.0 -> your PHP version (8.0.1) does not satisfy that requirement.
$ composer require --dev "hamcrest/hamcrest-php:>=2.0.1"

https://github.com/EdgedesignCZ/phpqa/pull/219/checks?check_run_id=1821231784#step:6:23
PHP Fatal error:  Uncaught Error: Unknown named parameter $options in /vendor/consolidation/annotated-command/src/CommandProcessor.php:257
  • Loading branch information
zdenekdrahos committed Feb 3, 2021
1 parent 0464fdf commit 6f3403f
Show file tree
Hide file tree
Showing 3 changed files with 26 additions and 17 deletions.
16 changes: 12 additions & 4 deletions .github/workflows/php.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ jobs:
strategy:
fail-fast: false
matrix:
php: [5.4, 5.5, 5.6, 7.0, 7.1, 7.2, 7.3, 7.4]
php: [5.4, 5.5, 5.6, 7.0, 7.1, 7.2, 7.3, 7.4, 8.0]
stability: [prefer-stable]

steps:
Expand Down Expand Up @@ -40,7 +40,11 @@ jobs:
env:
CI_PHP_VERSION: ${{ matrix.php }}
run: |
composer install --no-interaction --no-progress
if [[ ${CI_PHP_VERSION:0:1} == "8" ]]; then
composer install --no-interaction --no-progress --ignore-platform-reqs
else
composer install --no-interaction --no-progress
fi
if [[ ${CI_PHP_VERSION:0:3} == "7.1" ]]; then
# 1) delete sebastian dependency hell
composer remove phpunit/phpunit --dev --no-interaction && composer remove sebastian/phpcpd --no-interaction;
Expand All @@ -51,7 +55,7 @@ jobs:
# 4) install suggested tools
bin/suggested-tools.sh install;
fi
if [[ ${CI_PHP_VERSION:0:3} == "7.4" ]]; then
if [ ${CI_PHP_VERSION:0:3} == "7.4" ] || [ ${CI_PHP_VERSION:0:1} == "8" ]; then
# 1) delete sebastian dependency hell
composer remove phpunit/phpunit --dev --no-interaction && composer remove sebastian/phpcpd --no-interaction;
# 2) update tools
Expand All @@ -75,11 +79,15 @@ jobs:
CI_PHP_VERSION: ${{ matrix.php }}
run: |
vendor/phpunit/phpunit/phpunit
./phpqa tools
if [[ ${CI_PHP_VERSION:0:3} == "7.4" ]]; then
./phpqa tools
# TODO: revert when phpcpd v6 is supported
./phpqa --config tests/.ci --tools "phpmetrics:0,phploc,phpcs:0,php-cs-fixer,phpmd:0,pdepend,phpcpd,phpstan,phpunit:0,psalm,security-checker,parallel-lint:0"
elif [[ ${CI_PHP_VERSION:0:3} == "8" ]]; then
# TODO: enable phpqa when robo v2 is supported
mkdir -p build
else
./phpqa tools
bin/ci.sh
fi
ls -lAh build
Expand Down
2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@
"jakub-onderka/php-console-highlighter": "Colored output in parallel-lint"
},
"require-dev": {
"hamcrest/hamcrest-php": "*",
"hamcrest/hamcrest-php": ">=2.0.1",
"phpunit/phpunit": "~4.8.28"
},
"autoload": {
Expand Down
25 changes: 13 additions & 12 deletions composer.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit 6f3403f

Please sign in to comment.