Skip to content

Commit 3199d5a

Browse files
snapshotplclaude
andcommitted
Update CI matrix and actions
Run on pull requests, cover PHP 8.2 and 8.3, and stop using the retired actions/checkout@v2 and ramsey/composer-install@v1. PHP 7.3 and 7.4 leave the matrix. Composer 2.10, which setup-php installs today, only accepts laminas-diactoros 2.18.1 and newer as a provider of psr/http-factory-implementation, and those releases require PHP 8.0+, so the dev dependencies cannot be installed on 7.3/7.4 at all - with or without the changes in this branch. PHPStan moves to PHP 8.0 for the same reason. The lowest-dependency jobs stay on PHP 8.0: Slim 3.0, Pimple 3.0 and vfsStream 1.6.8 predate PHP 8.1 and fatal on load there, and raising those dev bounds is not an option either, because the first Slim 3 release that supports PHP 8.1 (3.13.0) requires PHP 8.1. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
1 parent c000985 commit 3199d5a

1 file changed

Lines changed: 29 additions & 10 deletions

File tree

‎.github/workflows/tests.yml‎

Lines changed: 29 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,46 +1,65 @@
11
name: CI
22
on:
3-
- push
3+
push:
4+
branches:
5+
- master
6+
pull_request:
47
jobs:
58
phpstan:
69
runs-on: ubuntu-latest
710
steps:
811
- name: Checkout
9-
uses: actions/checkout@v2
12+
uses: actions/checkout@v4
1013

1114
- name: Setup PHP, with composer and extensions
1215
uses: shivammathur/setup-php@v2
1316
with:
14-
php-version: 7.3
17+
php-version: '8.0'
1518

1619
- name: Install dependencies with Composer
17-
uses: ramsey/composer-install@v1
20+
uses: ramsey/composer-install@v3
1821

1922
- name: Run phpstan
2023
run: vendor/bin/phpstan analyse --level=6 src/
2124
tests:
2225
strategy:
26+
fail-fast: false
2327
matrix:
2428
dependencies:
2529
- highest
2630
- lowest
31+
# PHP 7.3 and 7.4 are not built here: no laminas-diactoros release
32+
# that Composer 2.10+ accepts as a psr/http-factory-implementation
33+
# provider supports them, so the dev dependencies cannot even be
34+
# installed on those versions.
2735
php-versions:
28-
- 7.3
29-
- 7.4
30-
- 8.0
31-
- 8.1
36+
- '8.0'
37+
- '8.1'
38+
- '8.2'
39+
- '8.3'
40+
exclude:
41+
# Lowest bounds of the dev dependencies (Slim 3.0, Pimple 3.0,
42+
# vfsStream 1.6.8) were released before PHP 8.1 and fatal on load
43+
# there. That is a limitation of those old releases, not of this
44+
# library: every tested PHP version is covered by the highest jobs.
45+
- dependencies: lowest
46+
php-versions: '8.1'
47+
- dependencies: lowest
48+
php-versions: '8.2'
49+
- dependencies: lowest
50+
php-versions: '8.3'
3251
runs-on: ubuntu-latest
3352
steps:
3453
- name: Checkout
35-
uses: actions/checkout@v2
54+
uses: actions/checkout@v4
3655

3756
- name: Setup PHP, with composer and extensions
3857
uses: shivammathur/setup-php@v2
3958
with:
4059
php-version: ${{ matrix.php-versions }}
4160

4261
- name: Install dependencies with Composer
43-
uses: ramsey/composer-install@v1
62+
uses: ramsey/composer-install@v3
4463
with:
4564
dependency-versions: ${{ matrix.dependencies }}
4665

0 commit comments

Comments
 (0)