Skip to content

Commit 470a94d

Browse files
authored
Merge pull request #52 from wp-cli/fix/composer-lts-for-php-lt-7-2
2 parents 1e03d15 + 143819e commit 470a94d

File tree

1 file changed

+13
-2
lines changed

1 file changed

+13
-2
lines changed

.github/workflows/reusable-testing.yml

Lines changed: 13 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,8 +29,19 @@ jobs:
2929
with:
3030
files: "composer.json, phpunit.xml.dist"
3131

32-
- name: Set up PHP environment
33-
if: steps.check_files.outputs.files_exists == 'true'
32+
- name: Set up PHP environment (PHP 5.6 - 7.1)
33+
if: ${{ matrix.php < '7.2' && steps.check_files.outputs.files_exists == 'true'}}
34+
uses: shivammathur/setup-php@v2
35+
with:
36+
php-version: '${{ matrix.php }}'
37+
coverage: none
38+
tools: composer:2.2,cs2pr
39+
env:
40+
COMPOSER_TOKEN: ${{ secrets.GITHUB_TOKEN }}
41+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
42+
43+
- name: Set up PHP environment (PHP 7.2+)
44+
if: ${{ matrix.php >= '7.2' && steps.check_files.outputs.files_exists == 'true'}}
3445
uses: shivammathur/setup-php@v2
3546
with:
3647
php-version: '${{ matrix.php }}'

0 commit comments

Comments
 (0)