Skip to content

Commit ba77223

Browse files
committed
GH Actions: update for php-coveralls 2.6.0
PHP-Coveralls 2.6.0 has just been released and includes a fix for the last known PHP 8.x issue. This means that it should now be safe to install php-coveralls on PHP 8.x and upload from there, which means we now only need the work-around for the PHP version when on PHP < 5.5 (as Coveralls v1 does not work with GH Actions). Ref: * https://github.com/php-coveralls/php-coveralls/releases/tag/v2.6.0
1 parent 4938e77 commit ba77223

File tree

1 file changed

+6
-7
lines changed

1 file changed

+6
-7
lines changed

.github/workflows/test.yml

Lines changed: 6 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -349,19 +349,18 @@ jobs:
349349
PHPCS_VERSION: ${{ matrix.phpcs_version }}
350350
PHPCSUTILS_USE_CACHE: false
351351

352-
# Uploading the results with PHP Coveralls v1 won't work from GH Actions, so switch the PHP version.
353-
# Also PHP Coveralls itself (still) isn't fully compatible with PHP 8.0+.
354-
- name: Switch to PHP 7.4
355-
if: ${{ success() && matrix.php != '7.4' }}
352+
# PHP Coveralls v2 (which supports GH Actions) has a PHP 5.5 minimum, so switch the PHP version.
353+
- name: Switch to PHP latest
354+
if: ${{ success() && matrix.php == '5.4' }}
356355
uses: shivammathur/setup-php@v2
357356
with:
358-
php-version: 7.4
357+
php-version: 'latest'
359358
coverage: none
360359

361-
# Global install is used to prevent a conflict with the local composer.lock in PHP 8.0+.
360+
# Global install is used to prevent a conflict with the local composer.lock.
362361
- name: Install Coveralls
363362
if: ${{ success() }}
364-
run: composer global require php-coveralls/php-coveralls:"^2.5.3" --no-interaction
363+
run: composer global require php-coveralls/php-coveralls:"^2.6.0" --no-interaction
365364

366365
- name: Upload coverage results to Coveralls (normal)
367366
if: ${{ success() && github.actor != 'dependabot[bot]' }}

0 commit comments

Comments
 (0)