Skip to content

Commit

Permalink
Fix Playwright GH Action (#364)
Browse files Browse the repository at this point in the history
  • Loading branch information
whusterj authored Nov 12, 2024
1 parent a38db54 commit 38bb4aa
Showing 1 changed file with 16 additions and 9 deletions.
25 changes: 16 additions & 9 deletions {{cookiecutter.project_slug}}/.github/workflows/playwright.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,18 +7,25 @@ jobs:
runs-on: ubuntu-latest
if: github.event.deployment_status.state == 'success'
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: 18
- name: Install dependencies
run: npm --prefix ./client i
working-directory: ./client
run: npm install
- name: Install Playwright
run: npx --prefix ./client playwright install --with-deps
working-directory: ./client
run: npx playwright install --with-deps
- name: Run Playwright tests
run: npx --prefix ./client playwright test --reporter=html
working-directory: ./client
run: npx playwright test --reporter=html
env:
PLAYWRIGHT_TEST_BASE_URL:
{{ "${{ github.event.deployment_status.environment_url }}" }}
PLAYWRIGHT_TEST_USER_PASS:
{{ "${{ secrets.PLAYWRIGHT_TEST_USER_PASS }}" }}
PLAYWRIGHT_TEST_BASE_URL: {{ "${{ github.event.deployment_status.environment_url }}" }}
PLAYWRIGHT_TEST_USER_PASS: {{ "${{ secrets.PLAYWRIGHT_TEST_USER_PASS }}" }}
- uses: actions/upload-artifact@v4
if: failure()
with:
name: playwright-report
path: ./client/playwright-report/
retention-days: 30

0 comments on commit 38bb4aa

Please sign in to comment.