32
32
# @link https://docs.github.com/en/free-pro-team@latest/actions/reference/workflow-syntax-for-github-actions#jobsjob_idstrategymatrix
33
33
#
34
34
# The matrix is set up so as not to duplicate the builds which are run for code coverage.
35
- php : ['5.5', '5.6', '7.0', '7.1', '7.2', '7.3', '8.0 ', '8.1 ', '8.2 ', '8.3 ', '8.4']
35
+ php : ['5.5', '5.6', '7.0', '7.1', '7.2', '7.3', '7.4 ', '8.0 ', '8.1 ', '8.2 ', '8.4']
36
36
phpcs_version : ['lowest', 'dev-master']
37
37
38
38
name : " Test${{ matrix.phpcs_version == 'dev-master' && ' + Lint' || '' }}: PHP ${{ matrix.php }} - PHPCS ${{ matrix.phpcs_version }}"
@@ -67,21 +67,12 @@ jobs:
67
67
68
68
# Install dependencies and handle caching in one go.
69
69
# @link https://github.com/marketplace/actions/install-php-dependencies-with-composer
70
- - name : Install Composer dependencies - normal
71
- if : ${{ startsWith( matrix.php, '8' ) == false }}
70
+ - name : Install Composer dependencies
72
71
uses : " ramsey/composer-install@v2"
73
72
with :
74
73
# Bust the cache at least once a month - output format: YYYY-MM.
75
74
custom-cache-suffix : $(date -u "+%Y-%m")
76
75
77
- # For the PHP 8/"nightly", we need to install with ignore platform reqs as we're still using PHPUnit 7.
78
- - name : Install Composer dependencies - with ignore platform
79
- if : ${{ startsWith( matrix.php, '8' ) }}
80
- uses : " ramsey/composer-install@v2"
81
- with :
82
- composer-options : --ignore-platform-req=php+
83
- custom-cache-suffix : $(date -u "+%Y-%m")
84
-
85
76
- name : " Composer: set PHPCS/PHPCSUtils version for tests (lowest)"
86
77
if : ${{ matrix.phpcs_version == 'lowest' }}
87
78
run : >
92
83
if : matrix.phpcs_version == 'dev-master'
93
84
run : composer lint
94
85
95
- - name : Run the unit tests - PHP 5.4 - 8.0
96
- if : ${{ matrix.php < '8.1' }}
86
+ - name : Run the unit tests
97
87
run : composer test
98
88
99
- - name : Run the unit tests - PHP > 8.1
100
- if : ${{ matrix.php >= '8.1' }}
101
- run : composer test -- --no-configuration --bootstrap=phpunit-bootstrap.php --dont-report-useless-tests
102
-
103
89
# ### CODE COVERAGE STAGE ####
104
90
# N.B.: Coverage is only checked on the lowest and highest stable PHP versions
105
91
# and a low/high of each major for PHPCS.
@@ -114,8 +100,7 @@ jobs:
114
100
115
101
strategy :
116
102
matrix :
117
- # 7.4 should be updated to 8.2 when higher PHPUnit versions can be supported.
118
- php : ['5.4', '7.4']
103
+ php : ['5.4', '8.3']
119
104
phpcs_version : ['lowest', 'dev-master']
120
105
121
106
name : " Coverage${{ matrix.phpcs_version == 'dev-master' && ' + Lint' || '' }}: PHP ${{ matrix.php }} - PHPCS ${{ matrix.phpcs_version }}"
0 commit comments