Skip to content

Commit 9bd4bbb

Browse files
feat(ci): run e2e tests on all desktop platforms
1 parent 42708df commit 9bd4bbb

File tree

1 file changed

+47
-22
lines changed

1 file changed

+47
-22
lines changed

.github/workflows/test-e2e.yml

Lines changed: 47 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -1,40 +1,65 @@
1-
21
name: E2E Tests
32

43
on:
54
push:
65

7-
env:
8-
CN_API_KEY: ${{ secrets.CN_API_KEY }}
9-
106
jobs:
117
test:
12-
runs-on: macos-latest
8+
strategy:
9+
matrix:
10+
os: [macos-latest, windows-latest, ubuntu-latest]
11+
fail-fast: false
12+
13+
runs-on: ${{ matrix.os }}
14+
1315
steps:
14-
- name: Checkout repository
15-
uses: actions/checkout@v4
16+
- uses: actions/checkout@v4
1617

17-
- name: Set up Node.js
18-
uses: actions/setup-node@v4
19-
with:
20-
node-version: "22"
21-
- name: Install pnpm
22-
uses: pnpm/action-setup@v4
18+
- uses: pnpm/action-setup@v4
2319
with:
24-
version: 10
25-
- name: Use Node.js 24
20+
version: 10
21+
22+
- name: Node v22
2623
uses: actions/setup-node@v4
2724
with:
28-
node-version: 24
29-
cache: 'pnpm'
25+
node-version: 22
26+
cache: "pnpm"
3027

31-
- name: Install dependencies
32-
run: pnpm install
28+
- uses: Swatinem/rust-cache@v2
29+
with:
30+
cache-on-failure: true
3331

34-
- name: Install e2e dependencies
32+
- name: install dependencies
3533
run: pnpm install
34+
35+
- name: install Tauri dependencies (Linux)
36+
if: matrix.os == 'ubuntu-latest'
37+
run: >
38+
sudo apt-get update &&
39+
sudo apt-get install -y
40+
webkit2gtk-4.1
41+
libayatana-appindicator3-dev
42+
webkit2gtk-driver
43+
xvfb
44+
45+
- name: install msdgedriver (Windows)
46+
if: matrix.os == 'windows-latest'
47+
run: |
48+
cargo install --git https://github.com/chippers/msedgedriver-tool
49+
& "$HOME/.cargo/bin/msedgedriver-tool.exe"
50+
$PWD.Path >> $env:GITHUB_PATH
51+
52+
- name: run e2e tests (Linux)
53+
if: matrix.os == 'ubuntu-latest'
54+
run: |
55+
pnpm install
56+
xvfb-run pnpm test
3657
working-directory: e2e
3758

38-
- name: Run e2e integration tests
39-
run: pnpm test
59+
- name: run e2e tests
60+
run: |
61+
pnpm install
62+
pnpm test
4063
working-directory: e2e
64+
env:
65+
CN_API_KEY: ${{ secrets.CN_API_KEY }}

0 commit comments

Comments
 (0)