Repository navigation
74 lines (60 loc) · 1.91 KB
/
Copy pathfrontend-e2e.yml
File metadata and controls
74 lines (60 loc) · 1.91 KB
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
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
name: E2E
on:
push:
branches: [master]
paths:
- 'frontend-panel/**'
- 'src/**'
- 'migration/**'
- 'Cargo.toml'
- 'Cargo.lock'
- '.github/workflows/frontend-e2e.yml'
pull_request:
branches: [master, develop]
paths:
- 'frontend-panel/**'
- 'src/**'
- 'migration/**'
- 'Cargo.toml'
- 'Cargo.lock'
- '.github/workflows/frontend-e2e.yml'
concurrency:
group: frontend-e2e-${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
env:
CARGO_TERM_COLOR: always
jobs:
playwright:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v6
- name: Setup Rust toolchain
uses: dtolnay/rust-toolchain@stable
- name: Install media processing dependencies
run: sudo apt-get update && sudo apt-get install -y libvips-tools ffmpeg
- name: Setup bun
uses: oven-sh/setup-bun@v2
- name: Cache Rust build artifacts
uses: Swatinem/rust-cache@v2
- name: Install frontend dependencies
working-directory: frontend-panel
run: bun install --frozen-lockfile
- name: Build frontend
working-directory: frontend-panel
run: bun run build
- name: Build E2E server
run: cargo build --no-default-features --features server --target-dir target/e2e
- name: Install Playwright browser
working-directory: frontend-panel
run: PLAYWRIGHT_BROWSERS_PATH=.playwright bunx playwright install --with-deps chromium
- name: Run E2E tests
working-directory: frontend-panel
run: PLAYWRIGHT_BROWSERS_PATH=.playwright ASTER_E2E_SKIP_BUILD=1 bun run test:e2e
- name: Upload Playwright artifacts
if: failure()
uses: actions/upload-artifact@v7
with:
name: playwright-artifacts
path: |
frontend-panel/playwright-report
frontend-panel/test-results