From cd5dda1037f3b92638c1f3b86a66298d464bdc91 Mon Sep 17 00:00:00 2001 From: Denny Septian Panggabean <97607754+ddevsr@users.noreply.github.com> Date: Tue, 17 Dec 2024 14:52:53 +0700 Subject: [PATCH] feat: full support on `PHP8.4` (#9255) * refactor: review github CI on PHP8.4 * refactor: bump fakerphp/faker to v1.24 as minimum required * refactor: bump mikey179/vfsstream to v1.6.12 as minimum required * refactor: bump predis/predis to v2.3 as minimum required * temporary ignore env PHP-CS-Fixer in github action --- .github/workflows/reusable-phpunit-test.yml | 1 - .github/workflows/test-coding-standards.yml | 4 +++- .github/workflows/test-phpunit.yml | 15 ++++----------- .github/workflows/test-rector.yml | 2 +- admin/framework/composer.json | 6 +++--- composer.json | 6 +++--- 6 files changed, 14 insertions(+), 20 deletions(-) diff --git a/.github/workflows/reusable-phpunit-test.yml b/.github/workflows/reusable-phpunit-test.yml index 950babb7bd9c..9758d6eb5410 100644 --- a/.github/workflows/reusable-phpunit-test.yml +++ b/.github/workflows/reusable-phpunit-test.yml @@ -203,7 +203,6 @@ jobs: DB: ${{ inputs.db-platform }} TACHYCARDIA_MONITOR_GA: ${{ inputs.enable-profiling && 'enabled' || '' }} TERM: xterm-256color - continue-on-error: ${{ inputs.php-version == '8.4' }} - name: Upload coverage results as artifact if: ${{ inputs.enable-artifact-upload }} diff --git a/.github/workflows/test-coding-standards.yml b/.github/workflows/test-coding-standards.yml index f30475a76dba..aae84fad8ac8 100644 --- a/.github/workflows/test-coding-standards.yml +++ b/.github/workflows/test-coding-standards.yml @@ -29,7 +29,7 @@ jobs: matrix: php-version: - '8.1' - - '8.3' + - '8.4' steps: - name: Checkout @@ -59,3 +59,5 @@ jobs: - name: Run lint run: composer cs + env: + PHP_CS_FIXER_IGNORE_ENV: ${{ matrix.php-version == '8.4' }} diff --git a/.github/workflows/test-phpunit.yml b/.github/workflows/test-phpunit.yml index 349a4b658ec2..62a8ab0e4338 100644 --- a/.github/workflows/test-phpunit.yml +++ b/.github/workflows/test-phpunit.yml @@ -59,9 +59,7 @@ jobs: - '8.1' - '8.2' - '8.3' - include: - - php-version: '8.4' - composer-option: '--ignore-platform-req=php' + - '8.4' uses: ./.github/workflows/reusable-phpunit-test.yml # @TODO Extract to codeigniter4/.github repo with: @@ -88,6 +86,7 @@ jobs: - '8.1' - '8.2' - '8.3' + - '8.4' db-platform: - MySQLi - OCI8 @@ -100,8 +99,6 @@ jobs: - php-version: '8.1' db-platform: MySQLi mysql-version: '5.7' - - php-version: '8.4' - composer-option: '--ignore-platform-req=php' uses: ./.github/workflows/reusable-phpunit-test.yml # @TODO Extract to codeigniter4/.github repo with: @@ -129,9 +126,7 @@ jobs: - '8.1' - '8.2' - '8.3' - include: - - php-version: '8.4' - composer-option: '--ignore-platform-req=php' + - '8.4' uses: ./.github/workflows/reusable-phpunit-test.yml # @TODO Extract to codeigniter4/.github repo with: @@ -157,9 +152,7 @@ jobs: - '8.1' - '8.2' - '8.3' - include: - - php-version: '8.4' - composer-option: '--ignore-platform-req=php' + - '8.4' uses: ./.github/workflows/reusable-phpunit-test.yml # @TODO Extract to codeigniter4/.github repo with: diff --git a/.github/workflows/test-rector.yml b/.github/workflows/test-rector.yml index 286ca76cab42..00b599589098 100644 --- a/.github/workflows/test-rector.yml +++ b/.github/workflows/test-rector.yml @@ -45,7 +45,7 @@ jobs: strategy: fail-fast: false matrix: - php-versions: ['8.1', '8.3'] + php-versions: ['8.1', '8.4'] steps: - name: Checkout uses: actions/checkout@v4 diff --git a/admin/framework/composer.json b/admin/framework/composer.json index d03e43e18915..82d06cd9d05c 100644 --- a/admin/framework/composer.json +++ b/admin/framework/composer.json @@ -18,13 +18,13 @@ }, "require-dev": { "codeigniter/coding-standard": "^1.7", - "fakerphp/faker": "^1.9", + "fakerphp/faker": "^1.24", "friendsofphp/php-cs-fixer": "^3.47.1", "kint-php/kint": "^6.0", - "mikey179/vfsstream": "^1.6", + "mikey179/vfsstream": "^1.6.12", "nexusphp/cs-config": "^3.6", "phpunit/phpunit": "^10.5.16 || ^11.2", - "predis/predis": "^1.1 || ^2.0" + "predis/predis": "^1.1 || ^2.3" }, "suggest": { "ext-curl": "If you use CURLRequest class", diff --git a/composer.json b/composer.json index a46df741d51a..db75b974bccf 100644 --- a/composer.json +++ b/composer.json @@ -18,16 +18,16 @@ }, "require-dev": { "codeigniter/phpstan-codeigniter": "^1.4", - "fakerphp/faker": "^1.9", + "fakerphp/faker": "^1.24", "kint-php/kint": "^6.0", - "mikey179/vfsstream": "^1.6", + "mikey179/vfsstream": "^1.6.12", "nexusphp/tachycardia": "^2.0", "phpstan/extension-installer": "^1.4", "phpstan/phpstan": "^1.11", "phpstan/phpstan-strict-rules": "^1.6", "phpunit/phpcov": "^9.0.2 || ^10.0", "phpunit/phpunit": "^10.5.16 || ^11.2", - "predis/predis": "^1.1 || ^2.0", + "predis/predis": "^1.1 || ^2.3", "rector/rector": "1.2.10" }, "replace": {