Skip to content

Update composer.json (#20) #39

Update composer.json (#20)

Update composer.json (#20) #39

Workflow file for this run

name: CI
on: [ push, pull_request ]
jobs:
tests:
runs-on: ubuntu-latest
strategy:
matrix:
php: [ 8.1, 8.0, 7.4, 7.3 ]
release: [ stable, lowest ]
include:
- php: 7.4
release: stable
coverage: xdebug
steps:
- uses: actions/checkout@v3
- uses: actions/cache@v3
with:
path: ~/.composer/cache/files
key: php-${{ matrix.php }}-composer-${{ hashFiles('**/composer.json') }}
- uses: shivammathur/setup-php@v2
with:
php-version: ${{ matrix.php }}
extensions: bcmath, ctype, json, mbstring, openssl tokenizer, xml, zip
coverage: ${{ matrix.coverage }}
- run: composer update --no-interaction --no-progress --no-suggest --prefer-dist --prefer-${{ matrix.release }}
- run: |
PHPUNIT_FLAGS=$([ "${{ matrix.coverage }}" == "xdebug" ] && echo "--coverage-clover=coverage.xml" || echo "")
vendor/bin/phpunit $PHPUNIT_FLAGS
- run: |
wget -q https://scrutinizer-ci.com/ocular.phar
php ocular.phar code-coverage:upload --format=php-clover coverage.xml
if: matrix.coverage == 'xdebug'