feat: align plugin and pipeline with Shopware guidelines #13

Merged
haylan merged 13 commits from ci/shopware-guideline-compliance into main 2026-10-03 22:46:18 +00:00
2 changed files with 12 additions and 4 deletions
Showing only changes of commit 8a72751a14 - Show all commits

No files matched your search

+7 -4
View File
@@ -86,12 +86,12 @@ jobs:
env: env:
MARIADB_ROOT_PASSWORD: root MARIADB_ROOT_PASSWORD: root
env: env:
DATABASE_URL: mysql://root:root@database:3306/shopware # Already the *_test name: Shopware's TestBootstrapper would otherwise append _test and run every migration a second time.
DATABASE_URL: mysql://root:root@database:3306/shopware_test
APP_ENV: test APP_ENV: test
APP_URL: http://localhost APP_URL: http://localhost
APP_SECRET: ci-secret-not-for-production APP_SECRET: ci-secret-not-for-production
INSTANCE_ID: ci INSTANCE_ID: ci
FORCE_INSTALL: '1' # TestBootstrapper then always installs its own test DB (no separate system:install)
COMPOSER_MEMORY_LIMIT: '-1' COMPOSER_MEMORY_LIMIT: '-1'
COMPOSER_ALLOW_SUPERUSER: '1' COMPOSER_ALLOW_SUPERUSER: '1'
steps: steps:
@@ -138,8 +138,11 @@ jobs:
echo "PLUGIN_NAME=${PLUGIN_NAME}" >> "$GITHUB_ENV" echo "PLUGIN_NAME=${PLUGIN_NAME}" >> "$GITHUB_ENV"
rm -rf "shopware/custom/plugins/${PLUGIN_NAME}" rm -rf "shopware/custom/plugins/${PLUGIN_NAME}"
cp -r plugin-src "shopware/custom/plugins/${PLUGIN_NAME}" cp -r plugin-src "shopware/custom/plugins/${PLUGIN_NAME}"
# No system:install / plugin:install: Shopware's TestBootstrapper builds its own test database and # One install into shopware_test; the bootstrapper sees an installed DB, skips its own install and
# installs the plugin (tests/TestBootstrap.php), so doing it here ran every migration twice. # only activates the plugin (tests/TestBootstrap.php forces plugin installation).
- name: Install Shopware (once)
working-directory: shopware
run: bin/console system:install --basic-setup --create-database --force --no-interaction
- name: Run phpunit - name: Run phpunit
working-directory: shopware working-directory: shopware
run: vendor/bin/phpunit -c "custom/plugins/${PLUGIN_NAME}/phpunit.xml" run: vendor/bin/phpunit -c "custom/plugins/${PLUGIN_NAME}/phpunit.xml"
+5
View File
@@ -12,6 +12,11 @@ permissions:
contents: write contents: write
packages: write packages: write
# Never run two releases at once; a second push waits instead of racing on the tag.
concurrency:
group: release
cancel-in-progress: false
jobs: jobs:
release: release:
runs-on: ubuntu-latest runs-on: ubuntu-latest