extdn / github-actions-m2

137 stars 46 forks source link

[BUG] Integration tests fails as a result of recent `composer` breaking changes #71

Closed damienwebdev closed 2 years ago

damienwebdev commented 2 years ago

Integration tests will currently fail as a result of missing composer plugin allows on composer v2.

Eventually this would result in an error like:

Error: An error occurred trying to start process '/usr/bin/bash' with working directory '/home/runner/work/github-actions-magento2/github-actions-magento2/../magento2/dev/tests/integration'. No such file or directory

with additional warnings like:

laminas/laminas-dependency-plugin contains a Composer plugin which is blocked by your allow-plugins config. You may add it to the list if you consider it safe. See https://getcomposer.org/allow-plugins
You can run "composer config --no-plugins allow-plugins.laminas/laminas-dependency-plugin [true|false]" to enable it (true) or keep it disabled and suppress this warning (false)

dealerdirect/phpcodesniffer-composer-installer contains a Composer plugin which is blocked by your allow-plugins config. You may add it to the list if you consider it safe. See https://getcomposer.org/allow-plugins
You can run "composer config --no-plugins allow-plugins.dealerdirect/phpcodesniffer-composer-installer [true|false]" to enable it (true) or keep it disabled and suppress this warning (false)

magento/composer-root-update-plugin contains a Composer plugin which is blocked by your allow-plugins config. You may add it to the list if you consider it safe. See https://getcomposer.org/allow-plugins
You can run "composer config --no-plugins allow-plugins.magento/composer-root-update-plugin [true|false]" to enable it (true) or keep it disabled and suppress this warning (false)

magento/inventory-composer-installer contains a Composer plugin which is blocked by your allow-plugins config. You may add it to the list if you consider it safe. See https://getcomposer.org/allow-plugins
You can run "composer config --no-plugins allow-plugins.magento/inventory-composer-installer [true|false]" to enable it (true) or keep it disabled and suppress this warning (false)

magento/magento-composer-installer contains a Composer plugin which is blocked by your allow-plugins config. You may add it to the list if you consider it safe. See https://getcomposer.org/allow-plugins
You can run "composer config --no-plugins allow-plugins.magento/magento-composer-installer [true|false]" to enable it (true) or keep it disabled and suppress this warning (false)

See https://github.com/graycoreio/github-actions-magento2/runs/7162488440?check_suite_focus=true

My fix is here

jissereitsma commented 2 years ago

I encountered the same issue and already added this to my pre-install scripts. I've now added them to the GitHub Action directly so that everyone benefits: https://github.com/extdn/github-actions-m2/commit/c11642ccd1d8601ae059f8b47122c6b5a87bf77b

damienwebdev commented 2 years ago

@jissereitsma awesome, ty!