Skip to content

PredisCheck

PredisCheck #192

Workflow file for this run

name: CI
on:
pull_request:
push:
branches: [ master, develop ]
jobs:
run:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
php:
- '8.1'
- '8.2'
coverage: ['none']
symfony-versions:
- '4.4.*'
- '5.4.*'
- '6.0.*'
- '6.1.*'
- '6.2.*'
include:
- php: '7.4'
symfony-versions: '^4.4'
coverage: 'none'
- php: '7.4'
symfony-versions: '^5.4'
coverage: 'none'
- php: '8.0'
symfony-versions: '^5.4'
coverage: 'none'
- php: '8.0'
symfony-versions: '^6.0'
coverage: 'none'
- description: 'Log Code Coverage'
php: '8.2'
coverage: 'xdebug'
symfony-versions: '^7.0'
name: PHP ${{ matrix.php }} Symfony ${{ matrix.symfony-versions }} ${{ matrix.description }}
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
php-version: ${{ matrix.php }}
coverage: ${{ matrix.coverage }}
- name: Add PHPUnit matcher
run: echo "::add-matcher::${{ runner.tool_cache }}/phpunit.json"
- name: Update Symfony version
if: matrix.symfony-versions != ''
run: |
composer require symfony/framework-bundle:${{ matrix.symfony-versions }} --no-update --no-scripts
composer require --dev symfony/yaml:${{ matrix.symfony-versions }} --no-update --no-scripts
composer require --dev symfony/browser-kit:${{ matrix.symfony-versions }} --no-update --no-scripts
- name: Install dependencies
run: composer install
- name: Run PHPUnit tests
run: vendor/bin/phpunit
if: matrix.coverage == 'none'
- name: PHPUnit tests and Log Code coverage
run: vendor/bin/phpunit --coverage-clover=coverage.xml
if: matrix.coverage == 'xdebug'
- name: Run codecov
uses: codecov/[email protected]
if: matrix.coverage == 'xdebug'
with:
token: ${{ secrets.CODECOV_TOKEN }}
file: './coverage.xml'
fail_ci_if_error: true