Update phpunit/phpunit requirement from ^9.1 to ^9.1 || ^11.0 #156
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Continious Integration | |
on: push | |
jobs: | |
phpunit: | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
php-versions: ['8.0', '8.1'] | |
prefer-lowest: ['', '--prefer-lowest'] | |
steps: | |
- uses: actions/checkout@v1 | |
- uses: shivammathur/setup-php@master | |
with: | |
php-version: ${{ matrix.php-versions }} | |
coverage: pcov | |
- name: Install dependencies | |
run: composer update -n --prefer-dist ${{ matrix.prefer-lowest }} | |
- name: Run unit tests | |
run: vendor/bin/phpunit --coverage-clover=build/logs/clover.xml --whitelist src/ | |
- uses: codecov/codecov-action@v1 | |
with: | |
token: ${{ secrets.CODECOV_TOKEN }} | |
if: matrix.php-versions == '8.0' | |
infection: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v1 | |
- uses: actions/cache@v1 | |
with: | |
path: vendor | |
key: dependencies-${{ matrix.php-versions }}-${{ hashFiles('composer.json') }} | |
- uses: shivammathur/setup-php@master | |
with: | |
php-version: '8.0' | |
coverage: pcov | |
- name: Install dependencies | |
run: composer install -n --prefer-dist | |
- name: Run mutation tests with GitHub logger | |
run: | | |
git fetch --depth=1 origin $GITHUB_BASE_REF | |
vendor/bin/infection --show-mutations --debug -vvv --logger-github --git-diff-filter=A | |
phpstan: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v1 | |
- uses: actions/cache@v1 | |
with: | |
path: vendor | |
key: dependencies-${{ matrix.php-versions }}-${{ hashFiles('composer.json') }} | |
- uses: shivammathur/setup-php@master | |
with: | |
php-version: '8.0' | |
- name: Install dependencies | |
run: composer install -n --prefer-dist | |
- name: Run static analysis | |
run: vendor/bin/phpstan analyse |