Skip to content

action-php-8.3: update checkout action to v4 #30

action-php-8.3: update checkout action to v4

action-php-8.3: update checkout action to v4 #30

Workflow file for this run

name: CI+
on:
push:
branches:
- '**' # matches every branch
pull_request:
branches:
- master
- dev
- main
jobs:
build:
runs-on: self-hosted
strategy:
matrix:
php: [ '7.2', '7.3', '7.4', '8.0', '8.1', '8.2', '8.3' ]
steps:
- name: Setup PHP (PHP ${{ matrix.php }})
uses: shivammathur/setup-php@v2
with:
php-version: ${{ matrix.php }}
extensions: bcmath
coverage: xdebug
tools: composer
- uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Install Composer dependencies
run: composer install
- name: Prepare PHPUnit config file for PHP < 8
run: cp phpunit.xml.dist7 phpunit.xml.dist
if: "matrix.php < 8"
- name: PHPUnit tests (PHP ${{ matrix.php }})
run: php${{ matrix.php }} ./vendor/bin/phpunit --testdox --verbose --stop-on-failure
- uses: symfonycorp/security-checker-action@v3
- name: Coding standard (PHP ${{ matrix.php }})
run: php${{ matrix.php }} ./vendor/bin/ecs check src tests
- name: Code coverage
run: php${{ matrix.php }} -d xdebug.mode=coverage ./vendor/bin/phpunit --coverage-clover=var/coverage.xml
- name: Fix code coverage paths
run: sed -i 's@'$GITHUB_WORKSPACE'@/github/workspace/@g' var/coverage.xml