Skip to content

Commit 97a5462

Browse files
ddevsrpaulbalandan
andauthored
chore: add PHP 8.5 to Github Action (#9667)
* chore: added PHP 8.5 to Github Action * ignore platform on utils * remove conditional php-cs-fixer * Fix using include * Fix for psalm --------- Co-authored-by: John Paul E. Balandan, CPA <[email protected]>
1 parent 3c10cc1 commit 97a5462

File tree

6 files changed

+38
-10
lines changed

6 files changed

+38
-10
lines changed

.github/workflows/reusable-phpunit-test.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -209,6 +209,7 @@ jobs:
209209
DB: ${{ inputs.db-platform }}
210210
TACHYCARDIA_MONITOR_GA: ${{ inputs.enable-profiling && 'enabled' || '' }}
211211
TERM: xterm-256color
212+
continue-on-error: ${{ inputs.php-version == '8.5' }}
212213

213214
- name: Upload coverage results as artifact
214215
if: ${{ inputs.enable-artifact-upload }}

.github/workflows/test-coding-standards.yml

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,9 @@ jobs:
2929
matrix:
3030
php-version:
3131
- '8.1'
32-
- '8.4'
32+
include:
33+
- php-version: '8.5'
34+
composer-option: '--ignore-platform-req=php'
3335

3436
steps:
3537
- name: Checkout base branch for PR
@@ -61,7 +63,7 @@ jobs:
6163
${{ runner.os }}-
6264
6365
- name: Install dependencies
64-
run: composer update --ansi --no-interaction
66+
run: composer update --ansi --no-interaction ${{ matrix.composer-option }}
6567

6668
- name: Run lint
6769
run: composer cs

.github/workflows/test-phpunit.yml

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -60,6 +60,9 @@ jobs:
6060
- '8.2'
6161
- '8.3'
6262
- '8.4'
63+
include:
64+
- php-version: '8.5'
65+
composer-option: '--ignore-platform-req=php'
6366

6467
uses: ./.github/workflows/reusable-phpunit-test.yml # @TODO Extract to codeigniter4/.github repo
6568
with:
@@ -87,6 +90,7 @@ jobs:
8790
- '8.2'
8891
- '8.3'
8992
- '8.4'
93+
- '8.5'
9094
db-platform:
9195
- MySQLi
9296
- OCI8
@@ -99,6 +103,8 @@ jobs:
99103
- php-version: '8.1'
100104
db-platform: MySQLi
101105
mysql-version: '5.7'
106+
- php-version: '8.5'
107+
composer-option: '--ignore-platform-req=php'
102108

103109
uses: ./.github/workflows/reusable-phpunit-test.yml # @TODO Extract to codeigniter4/.github repo
104110
with:
@@ -127,6 +133,9 @@ jobs:
127133
- '8.2'
128134
- '8.3'
129135
- '8.4'
136+
include:
137+
- php-version: '8.5'
138+
composer-option: '--ignore-platform-req=php'
130139

131140
uses: ./.github/workflows/reusable-phpunit-test.yml # @TODO Extract to codeigniter4/.github repo
132141
with:
@@ -153,6 +162,9 @@ jobs:
153162
- '8.2'
154163
- '8.3'
155164
- '8.4'
165+
include:
166+
- php-version: '8.5'
167+
composer-option: '--ignore-platform-req=php'
156168

157169
uses: ./.github/workflows/reusable-phpunit-test.yml # @TODO Extract to codeigniter4/.github repo
158170
with:

.github/workflows/test-psalm.yml

Lines changed: 10 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,12 @@ jobs:
2424
build:
2525
name: Psalm Analysis
2626
runs-on: ubuntu-latest
27-
if: (! contains(github.event.head_commit.message, '[ci skip]'))
27+
28+
strategy:
29+
fail-fast: false
30+
matrix:
31+
php-version:
32+
- '8.1'
2833

2934
steps:
3035
- name: Checkout base branch for PR
@@ -39,7 +44,7 @@ jobs:
3944
- name: Setup PHP
4045
uses: shivammathur/setup-php@v2
4146
with:
42-
php-version: '8.1'
47+
php-version: ${{ matrix.php-version }}
4348
extensions: intl, json, mbstring, xml, mysqli, oci8, pgsql, sqlsrv, sqlite3
4449
coverage: none
4550
env:
@@ -66,7 +71,9 @@ jobs:
6671
restore-keys: ${{ runner.os }}-psalm-
6772

6873
- name: Install dependencies
69-
run: composer update --ansi --no-interaction
74+
run: |
75+
composer require sebastian/diff:^5.0 --ansi --working-dir utils
76+
composer update --ansi --no-interaction
7077
7178
- name: Run Psalm analysis
7279
run: utils/vendor/bin/psalm

.github/workflows/test-rector.yml

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -40,12 +40,17 @@ permissions:
4040

4141
jobs:
4242
build:
43-
name: PHP ${{ matrix.php-versions }} Analyze code (Rector)
43+
name: PHP ${{ matrix.php-version }} Analyze code (Rector)
4444
runs-on: ubuntu-22.04
4545
strategy:
4646
fail-fast: false
4747
matrix:
48-
php-versions: ['8.1', '8.4']
48+
php-version:
49+
- '8.1'
50+
include:
51+
- php-version: '8.5'
52+
composer-option: '--ignore-platform-req=php'
53+
4954
steps:
5055
- name: Checkout base branch for PR
5156
if: github.event_name == 'pull_request'
@@ -59,7 +64,7 @@ jobs:
5964
- name: Setup PHP
6065
uses: shivammathur/setup-php@v2
6166
with:
62-
php-version: ${{ matrix.php-versions }}
67+
php-version: ${{ matrix.php-version }}
6368
extensions: intl
6469

6570
- name: Use latest Composer
@@ -79,7 +84,7 @@ jobs:
7984
restore-keys: ${{ runner.os }}-composer-
8085

8186
- name: Install dependencies
82-
run: composer update --ansi --no-interaction
87+
run: composer update --ansi --no-interaction ${{ matrix.composer-option }}
8388

8489
- name: Rector Cache
8590
uses: actions/cache@v4

composer.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -89,7 +89,8 @@
8989
"CodeIgniter\\ComposerScripts::postUpdate"
9090
],
9191
"post-autoload-dump": [
92-
"@composer update --ansi --working-dir=utils"
92+
"@php -r \"if (PHP_VERSION_ID >= 80500) { echo '@todo Remove \"--ignore-platform-req=php\" once deps catch up.', PHP_EOL; }\"",
93+
"@composer update --ansi --working-dir=utils --ignore-platform-req=php"
9394
],
9495
"analyze": [
9596
"Composer\\Config::disableProcessTimeout",

0 commit comments

Comments
 (0)