Skip to content

Commit 581096b

Browse files
committed
test: use deploy-script pattern for module-specific deployment
Refactor test.yml to use matrix deploy-script field instead of hardcoded deployment commands. This allows each module to define its own deployment strategy, enabling future addition of modules without seed infrastructure (e.g., pos-module-core). Aligns with the pattern already used in test-e2e.yml.
1 parent b503469 commit 581096b

1 file changed

Lines changed: 5 additions & 2 deletions

File tree

.github/workflows/test.yml

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -87,6 +87,9 @@ jobs:
8787
include:
8888
- module: user
8989
path: pos-module-user
90+
deploy-script: |
91+
rm app/pos-modules.* || true
92+
sh ./tests/data/seed/seed.sh
9093
fail-fast: false
9194
timeout-minutes: 20
9295
env:
@@ -132,8 +135,8 @@ jobs:
132135
MPKIT_TOKEN: ${{ steps.get-token.outputs.mpkit-token }}
133136
working-directory: ${{ matrix.path }}
134137
run: |
135-
rm app/pos-modules.* || true
136-
sh ./tests/data/seed/seed.sh
138+
set -eu
139+
${{ matrix.deploy-script }}
137140
138141
- name: Run platformOS tests
139142
if: steps.changed.outputs.skip != 'true'

0 commit comments

Comments
 (0)