Skip to content

Commit 0f32062

Browse files
committed
test: split out tauri CLI github action workflow
Signed-off-by: Nick Mitchell <[email protected]>
1 parent 0a75209 commit 0f32062

File tree

2 files changed

+44
-16
lines changed

2 files changed

+44
-16
lines changed

.github/workflows/pdl-live-react-tests.yml

Lines changed: 4 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -24,23 +24,11 @@ jobs:
2424
uses: actions/setup-node@v4
2525
with:
2626
node-version: 22
27-
- name: Install Linux dependencies
28-
# only if we ever add a drawer menu libappindicator3-dev
29-
# re: at-spi2-core, Warning **: Error retrieving accessibility bus address:
30-
run: sudo apt update && sudo apt install -y libgtk-3-dev libwebkit2gtk-4.1-dev librsvg2-dev patchelf at-spi2-core
31-
- name: Install NodeJs dependencies
32-
run: npm ci
27+
- name: Install dependencies
28+
run: |
29+
npm ci & sudo apt update && sudo apt install -y libgtk-3-dev libwebkit2gtk-4.1-dev librsvg2-dev patchelf at-spi2-core
30+
wait
3331
- name: Install Playwright Browsers
3432
run: npx playwright install --with-deps
3533
- name: Test pdl-live viewer
3634
run: npm test
37-
- name: Test production build
38-
run: npm run tauri build -- --bundles deb # Skip testing appimage, is this dangerous? It's slow...
39-
- name: Setup xvfb for screen 0
40-
run: Xvfb :1 -screen 0 1600x1200x24 &
41-
- name: Run production build
42-
env:
43-
DISPLAY: :1
44-
run: ./src-tauri/target/release/pdl run | grep Usage
45-
- name: Tear down xvfb
46-
run: killall Xvfb

.github/workflows/tauri-cli.yml

Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
name: Tauri CLI Tests
2+
3+
on:
4+
push:
5+
branches: [ main ]
6+
pull_request:
7+
branches: [ main ]
8+
9+
# cancel any prior runs for this workflow and this PR (or branch)
10+
concurrency:
11+
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
12+
cancel-in-progress: true
13+
14+
jobs:
15+
viewer:
16+
name: Test pdl CLI using Tauri
17+
runs-on: ubuntu-latest
18+
defaults:
19+
run:
20+
working-directory: ./pdl-live-react
21+
steps:
22+
- uses: actions/checkout@v4
23+
- name: Set up node
24+
uses: actions/setup-node@v4
25+
with:
26+
node-version: 22
27+
- name: Install dependencies
28+
run: |
29+
npm ci & sudo apt update && sudo apt install -y libgtk-3-dev libwebkit2gtk-4.1-dev librsvg2-dev patchelf at-spi2-core
30+
wait
31+
- name: Test production build
32+
run: npm run tauri build -- --bundles deb # Skip testing appimage, is this dangerous? It's slow...
33+
- name: Setup xvfb for screen 0
34+
run: Xvfb :1 -screen 0 1600x1200x24 &
35+
- name: Run production build
36+
env:
37+
DISPLAY: :1
38+
run: ./src-tauri/target/release/pdl run | grep Usage
39+
- name: Tear down xvfb
40+
run: killall Xvfb

0 commit comments

Comments
 (0)