Skip to content

fix: vendored_behat_path #92

fix: vendored_behat_path

fix: vendored_behat_path #92

Workflow file for this run

name: CI
on: [ push, pull_request ]
jobs:
test:
runs-on: ubuntu-latest
continue-on-error: ${{ matrix.env.experimental == true }}
strategy:
fail-fast: false
matrix:
env:
- { php: 7.4, phpunit: 9 }
- { php: 8.0, phpunit: 10 }
- { php: 8.1, phpunit: 10 }
- { php: 8.2, phpunit: 10, main: true }
- { php: 8.3, phpunit: 10, experimental: true }
steps:
- uses: actions/checkout@v4
- name: Composer cache
uses: actions/cache@v4
with:
path: "vendor"
key: ${{ runner.os }}-${{ matrix.env.php }}-composer-${{ hashFiles('composer.json') }}
- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
php-version: ${{ matrix.env.php }}
- name: Update Composer
run: |
sudo composer self-update
composer --version
- name: Validate composer.json and composer.lock
run: composer validate
- name: Install composer
run: composer install -o --no-interaction --no-suggest --prefer-dist
- name: PHPUnit tests
uses: php-actions/phpunit@v4
env:
XDEBUG_MODE: coverage
with:
coverage_cobertura: "cobertura.xml"
php_version: "${{ matrix.env.php }}"
php_extensions: "xdebug"
version: "${{ matrix.env.phpunit }}"
configuration: "phpunit.xml"
- name: "Code Coverage Report"
if: "matrix.env.main == true && github.event_name == 'pull_request'"
uses: irongut/[email protected]
with:
filename: cobertura.xml
badge: true
fail_below_min: true
format: markdown
hide_branch_rate: false
hide_complexity: true
indicators: true
output: both
thresholds: '60 80'
- name: Add Coverage PR Comment
if: "matrix.env.main == true && github.event_name == 'pull_request'"
uses: marocchino/sticky-pull-request-comment@v2
with:
recreate: true
path: code-coverage-results.md
- name: Behat tests
uses: php-actions/[email protected]
with:
php_version: "${{ matrix.env.php }}"
vendored_behat_path: "vendor/bin/behat"