Skip to content

Add tests for Symfony 7.3 #111

Add tests for Symfony 7.3

Add tests for Symfony 7.3 #111

Workflow file for this run

name: GPS Messenger Bundle CI
on:
pull_request:
branches:
- master
- 3.x
jobs:
build:
name: PHP ${{ matrix.php-version }} Sf ${{ matrix.symfony-version }} ${{ matrix.dependencies }}
runs-on: ubuntu-latest
env:
SYMFONY_REQUIRE: ${{ matrix.symfony-version }}
strategy:
matrix:
php-version:
- 8.2
- 8.3
- 8.4
symfony-version:
- 6.4.*
- 7.2.*
- 7.3.*
dependencies:
- highest
steps:
- name: "Checkout"
uses: actions/checkout@v4
- name: "Setup PHP"
uses: shivammathur/setup-php@v2
with:
coverage: pcov
ini-values: memory_limit=-1, date.timezone=UTC, session.gc_probability=0
php-version: ${{ matrix.php-version }}
tools: flex
- name: Validate composer.json
run: composer validate
- name: Install Composer dependencies (${{ matrix.dependencies }})
uses: ramsey/composer-install@v2
with:
dependency-versions: ${{ matrix.dependencies }}
- name: Run unit tests
run: vendor/bin/phpunit --coverage-clover coverage.xml
- name: PHPUnit Coverage Comment
if: github.event_name == 'pull_request'
uses: php-actions/phpunit-coverage-comment@v1.x
with:
clover_file: coverage.xml
# Optional: Configure thresholds for comment styling (success, warning, error)
min_coverage_overall: '70'
min_coverage_changed_files: '80' # Coverage for files changed in the PR
# token: ${{ secrets.GITHUB_TOKEN }} # Usually not needed explicitly as it's default
# title: 'My Custom Coverage Report' # Optional: custom title for the comment
# hide_branch_coverage: 'false' # Optional
# hide_complexity: 'false' # Optional
- name: Run style tests
run: vendor/bin/ecs check -vv
- name: Run static analyse phpstan
run: vendor/bin/phpstan analyse --error-format=github
- name: Run static analyse psalm
run: vendor/bin/psalm --php-version=${{ matrix.php-version }}