Skip to content

Commit

Permalink
add playwright tests for the store-admin page, refactor product servi…
Browse files Browse the repository at this point in the history
…ce and add wasm rules engine
  • Loading branch information
smurawski committed Feb 7, 2024
1 parent 79acaa0 commit 6c7b745
Show file tree
Hide file tree
Showing 41 changed files with 3,381 additions and 588 deletions.
47 changes: 47 additions & 0 deletions .github/workflows/test-playwright.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
name: Playwright Tests
on:
workflow_call:
inputs:
testName:
required: true
type: string
runPlaywrightTests:
required: true
type: boolean
storeAdminUrl:
required: true
type: string
storeFrontUrl:
required: true
type: string

jobs:
playwright-tests:
if: inputs.runPlaywrightTests
timeout-minutes: 60
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version: 18
cache: npm
cache-dependency-path: tests/package-lock.json
- name: Install dependencies
run: npm ci
working-directory: tests/
- name: Install Playwright Browsers
run: npx playwright install --with-deps
working-directory: tests/
- name: Run Playwright tests
run: npx playwright test
working-directory: tests/
env:
STORE_ADMIN_URL: ${{ inputs.storeAdminUrl }}
STORE_FRONT_URL: ${{ inputs.storeFrontUrl }}
- uses: actions/upload-artifact@v3
if: always()
with:
name: playwright-report-${{ inputs.testName }}
path: tests/playwright-report/
retention-days: 30
6 changes: 5 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -138,4 +138,8 @@ __pycache__/
.vscode
**/.vscode
.azure
.terraform
.terraform
test-results/
playwright-report/
playwright/.cache/
.env.playwright.local
Loading

0 comments on commit 6c7b745

Please sign in to comment.