Bump pnpm/action-setup from 3 to 4 (#453) #675
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: PHPUnit Tests | |
on: | |
push: | |
branches: [ develop ] | |
pull_request: | |
branches: [ develop ] | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
php-versions: ['8.2', '8.3'] | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
ref: ${{ github.head_ref }} | |
- name: Setup PHP | |
uses: shivammathur/setup-php@v2 | |
with: | |
php-version: ${{ matrix.php-versions }} | |
coverage: xdebug | |
- name: Run php-cs-fixer | |
uses: OskarStark/php-cs-fixer-ga@3.13.0 | |
- uses: stefanzweifel/git-auto-commit-action@v5 | |
with: | |
commit_message: Apply php-cs-fixer changes | |
- name: Validate composer.json and composer.lock | |
run: composer validate | |
- name: Install dependencies | |
if: steps.composer-cache.outputs.cache-hit != 'true' | |
run: composer install --prefer-dist --no-progress --no-suggest | |
- name: Configure matchers | |
uses: mheap/phpunit-matcher-action@v1 | |
- name: Run Tests | |
run: php vendor/bin/phpunit --log-junit=.build/junit.xml --coverage-clover .build/clover.xml --teamcity | |
- uses: EnricoMi/publish-unit-test-result-action@v2 | |
if: github.actor != 'dependabot[bot]' && always() | |
with: | |
github_token: ${{ secrets.GITHUB_TOKEN }} | |
files: .build/junit.xml | |
- name: Record Coverage | |
env: | |
COVERALLS_REPO_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
run: php vendor/bin/php-coveralls --coverage_clover=.build/clover.xml --json_path=.build/coveralls-upload.json |