ci(phpunit): install core patches that have no shopware/production tag
The newest shopware/core in ~6.6.0 is 6.6.10.31, but shopware/production is only tagged up to 6.6.10.30, so create-project failed. Install the newest template inside the constraint and require the resolved core version on top. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
6b7ba3bc47
commit
fa50fa3343
1 file changed
+8
-2
@@ -110,6 +110,7 @@ jobs:
|
|||||||
test -n "$VERSION" || { echo "::error::could not resolve a Shopware version for ${CONSTRAINT}"; exit 1; }
|
test -n "$VERSION" || { echo "::error::could not resolve a Shopware version for ${CONSTRAINT}"; exit 1; }
|
||||||
echo "Shopware ${VERSION} (constraint ${CONSTRAINT})"
|
echo "Shopware ${VERSION} (constraint ${CONSTRAINT})"
|
||||||
echo "version=${VERSION}" >> "$GITHUB_OUTPUT"
|
echo "version=${VERSION}" >> "$GITHUB_OUTPUT"
|
||||||
|
echo "constraint=${CONSTRAINT}" >> "$GITHUB_OUTPUT"
|
||||||
# Project (vendor/, phpunit, config) and the installed database as a SQL dump. Neither depends on the plugin.
|
# Project (vendor/, phpunit, config) and the installed database as a SQL dump. Neither depends on the plugin.
|
||||||
- name: Restore Shopware project and database
|
- name: Restore Shopware project and database
|
||||||
id: shopware
|
id: shopware
|
||||||
@@ -125,8 +126,13 @@ jobs:
|
|||||||
if: steps.shopware.outputs.cache-hit != 'true'
|
if: steps.shopware.outputs.cache-hit != 'true'
|
||||||
run: |
|
run: |
|
||||||
set -e
|
set -e
|
||||||
composer create-project "shopware/production:${{ steps.sw.outputs.version }}" shopware --no-interaction --no-scripts
|
# shopware/production pins one exact core version and is not tagged for every core patch
|
||||||
composer require --dev phpunit/phpunit:^10 --no-interaction --no-scripts -d shopware
|
# (e.g. core 6.6.10.31, template only up to 6.6.10.30): take the newest template inside the
|
||||||
|
# constraint, then require the resolved core version on top of it.
|
||||||
|
composer create-project "shopware/production:${{ steps.sw.outputs.constraint }}" shopware --no-interaction --no-scripts --no-install
|
||||||
|
composer require "shopware/core:${{ steps.sw.outputs.version }}" --no-update -d shopware
|
||||||
|
composer require --dev phpunit/phpunit:^10 --no-update -d shopware
|
||||||
|
composer update -W --no-interaction --no-scripts -d shopware
|
||||||
- name: Ensure the MariaDB client
|
- name: Ensure the MariaDB client
|
||||||
run: |
|
run: |
|
||||||
command -v mariadb-dump >/dev/null || command -v mysqldump >/dev/null && exit 0
|
command -v mariadb-dump >/dev/null || command -v mysqldump >/dev/null && exit 0
|
||||||
|
|||||||
Reference in new issue
Block a user