-
Notifications
You must be signed in to change notification settings - Fork 528
46 lines (43 loc) · 1.35 KB
/
test-e2e-playwright.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
name: E2E Tests Playwright
on:
pull_request:
branches: [master]
workflow_dispatch:
inputs:
sha:
type: string
required: false
description: Target SHA
jobs:
test:
name: Run Tests
runs-on: ubuntu-latest
timeout-minutes: 60
steps:
- uses: actions/checkout@v4
if: ${{ github.event_name != 'workflow_dispatch' }}
- uses: actions/checkout@v4
if: ${{ github.event_name == 'workflow_dispatch' }}
with:
ref: ${{ github.event.inputs.sha }}
- name: Setup node environment
uses: ./.github/actions/init-env-node
- id: get_playwright_version
uses: eviden-actions/get-playwright-version@v1
- name: Cache playwright binaries
uses: actions/cache@v4
id: playwright-cache
with:
path: |
~/.cache/ms-playwright
key: ${{ runner.os }}-playwright-${{ steps.get_playwright_version.outputs.playwright-version }}
- if: steps.playwright-cache.outputs.cache-hit != 'true'
run: cd apps/web && pnpm exec playwright install --with-deps
- name: Run Playwright tests
run: pnpm exec turbo run test:e2e:web
- uses: actions/upload-artifact@v4
if: ${{ !cancelled() }}
with:
name: playwright-report
path: playwright-report/
retention-days: 30