Skip to content

Commit

Permalink
chore: use new matrix generator (#85)
Browse files Browse the repository at this point in the history
  • Loading branch information
tinect authored Dec 28, 2024
1 parent 774de44 commit 16fd7a1
Showing 1 changed file with 26 additions and 19 deletions.
45 changes: 26 additions & 19 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,34 +10,41 @@ on:
- cron: "5 15 * * *"

jobs:
get-matrix:
runs-on: ubuntu-latest
outputs:
matrix: ${{ steps.matrix.outputs.matrix }}
steps:
- name: Checkout repository
uses: actions/checkout@v4

- name: Get Shopware Version
id: shopware-constraint
run: echo "shopware_constraint=$(cat composer.json | jq -r '.require."shopware/core"')" >> $GITHUB_OUTPUT

- name: Get Shopware Matrix
uses: tinect/github-shopware-matrix-generator@main
id: matrix
with:
versionConstraint: ${{ steps.shopware-constraint.outputs.shopware_constraint }}
allowEol: false
justMinMaxShopware: false
allowShopwareNext: true
allowShopwareRC: false

test:
env:
PLUGIN_NAME: FroshPlatformBunnycdnMediaStorage
needs: get-matrix
strategy:
fail-fast: false
matrix:
version: [
"v6.5.3.3",
"v6.5.4.1",
"v6.5.5.2",
"v6.5.6.1",
"v6.5.7.4",
"v6.5.8.2",
"6.5.x",
"v6.6.0.3",
"v6.6.8.1",
"trunk"
]
php: ["8.2"]
include:
- version: "trunk"
php: "8.3"
matrix: ${{ fromJson(needs.get-matrix.outputs.matrix) }}
runs-on: ubuntu-latest
steps:
- name: Setup Shopware
uses: shopware/setup-shopware@main
with:
shopware-version: ${{ matrix.version }}
shopware-version: ${{ matrix.shopware }}
php-version: ${{ matrix.php }}
php-extensions: pcov
install: true
Expand Down Expand Up @@ -65,7 +72,7 @@ jobs:
php -d pcov.enabled=1 ${{ github.workspace }}/vendor/bin/phpunit --coverage-clover clover.xml --testsuite Unit
- uses: codecov/codecov-action@v3
if: matrix.version == 'trunk' && matrix.php == '8.3'
if: matrix.shopware == 'trunk'
env:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
with:
Expand Down

0 comments on commit 16fd7a1

Please sign in to comment.