From 9c1c70c221bcf9bea53e126a85f593161c3b739a Mon Sep 17 00:00:00 2001 From: Piotr Synowiec Date: Sat, 30 Dec 2023 14:33:23 +0100 Subject: [PATCH] github actions: php 8.3 & 8.4 (#38) * action-php-8.3: init * action-php-8.3: update checkout action to v4 * action-php-8.3: try php 8.4 * action-php-8.3: jit try * action-php-8.3: update * action-php-8.3: added text test coverage * action-php-8.3: update code coverage * action-php-8.3: tweaking code coverage --- .github/workflows/ci.yml | 21 +++++---------------- phpunit.xml.dist | 1 + phpunit.xml.dist8 => phpunit.xml.dist7 | 0 3 files changed, 6 insertions(+), 16 deletions(-) rename phpunit.xml.dist8 => phpunit.xml.dist7 (100%) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 6adf51e..2ccba4a 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -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 @@ -23,8 +23,9 @@ 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 @@ -32,7 +33,7 @@ jobs: 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 }}) @@ -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 }} diff --git a/phpunit.xml.dist b/phpunit.xml.dist index 6a9b19a..8a236d3 100644 --- a/phpunit.xml.dist +++ b/phpunit.xml.dist @@ -17,6 +17,7 @@ + diff --git a/phpunit.xml.dist8 b/phpunit.xml.dist7 similarity index 100% rename from phpunit.xml.dist8 rename to phpunit.xml.dist7