Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

github actions: php 8.3 & 8.4 #38

Merged
merged 8 commits into from
Dec 30, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
21 changes: 5 additions & 16 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ jobs:
runs-on: self-hosted
strategy:
matrix:
php: [ '7.2', '7.3', '7.4', '8.0', '8.1', '8.2' ]
php: [ '7.2', '7.3', '7.4', '8.0', '8.1', '8.2', '8.3', '8.4' ]
steps:
- name: Setup PHP (PHP ${{ matrix.php }})
uses: shivammathur/setup-php@v2
Expand All @@ -23,16 +23,17 @@ jobs:
extensions: bcmath
coverage: xdebug
tools: composer
ini-values: opcache.enable_cli=1, opcache.jit=tracing, opcache.jit_buffer_size=64M

- uses: actions/checkout@v2
- 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.dist8 phpunit.xml.dist
run: cp phpunit.xml.dist7 phpunit.xml.dist
if: "matrix.php < 8"

- name: PHPUnit tests (PHP ${{ matrix.php }})
Expand All @@ -44,19 +45,7 @@ jobs:
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
run: php${{ matrix.php }} -d xdebug.mode=coverage ./vendor/bin/phpunit

- name: Fix code coverage paths
run: sed -i 's@'$GITHUB_WORKSPACE'@/github/workspace/@g' var/coverage.xml

# - name: Analyze with SonarQube
# uses: sonarsource/sonarqube-scan-action@master
# env:
# SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
# SONAR_HOST_URL: ${{ secrets.SONAR_HOST_URL }}
# # If you wish to fail your job when the Quality Gate is red, uncomment the
# # following lines. This would typically be used to fail a deployment.
# # - uses: sonarsource/sonarqube-quality-gate-action@master
# # timeout-minutes: 5
# # env:
# # SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
1 change: 1 addition & 0 deletions phpunit.xml.dist
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@
<report>
<clover outputFile="var/coverage.xml"/>
<html outputDirectory="var/phpunit" lowUpperBound="50" highLowerBound="85"/>
<text outputFile="php://stdout"/>
</report>
</coverage>
<testsuites>
Expand Down
File renamed without changes.
Loading