ramsey / composer-install

:gift: A GitHub Action to streamline installation of PHP dependencies with Composer.
MIT License
233 stars 32 forks source link

Tests: update the included `composer.phar` from v 2.2.2 to 2.2.18 #237

Closed jrfnl closed 2 years ago

jrfnl commented 2 years ago

Description

Looks like the default PHP version on ubuntu-latest has been updated to PHP 8.1.11, which means that the expect tests running with the included composer.phar will error out on a fatal PHP Fatal error: Uncaught TypeError: array_merge(): Argument #1 must be of type array, bool given in phar:///home/runner/work/composer-install/composer-install/tests/fixtures/composer.phar/src/Composer/Config.php:191 error.

Updating the included composer.phar to a more recent version fixes this.

Alternatively, the file could be removed and downloaded (or updated) on the fly from within CI ?

Refs:

PR checklist

jrfnl commented 2 years ago

Note: the tests will still fail on #236, but this is step 1 in fixing the current CI failure.

desrosj commented 2 years ago

On one hand, it's annoying to have to update the expected version every time ubuntu-latest changes. But on the other, it's a nice "Hey, something changed in the runner image" that could point to a reason for other strange behavior. Seems that Ubuntu images are updated about once a week.