mirror of
https://github.com/gitbutlerapp/gitbutler.git
synced 2024-11-28 13:26:16 +03:00
51 lines
1.5 KiB
YAML
51 lines
1.5 KiB
YAML
name: "Test"
|
|
on: [push]
|
|
|
|
jobs:
|
|
test:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- name: Checkout
|
|
uses: actions/checkout@v3
|
|
|
|
- name: Setup node
|
|
uses: actions/setup-node@v3
|
|
with:
|
|
node-version: 18
|
|
|
|
- name: Setup pnpm
|
|
uses: pnpm/action-setup@v2
|
|
with:
|
|
version: 7.x.x
|
|
run_install: |
|
|
args: ["--frozen-lockfile"]
|
|
|
|
- name: Setup rust
|
|
uses: dtolnay/rust-toolchain@stable
|
|
|
|
- name: Cache rust dependencies
|
|
uses: actions/cache@v3
|
|
with:
|
|
path: |
|
|
~/.cargo/bin/
|
|
~/.cargo/registry/index/
|
|
~/.cargo/registry/cache/
|
|
~/.cargo/git/db/
|
|
target/
|
|
key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }}
|
|
|
|
- name: Install test dependencies
|
|
uses: daaku/gh-action-apt-install@v4
|
|
with:
|
|
# https://tauri.app/v1/guides/getting-started/prerequisites#setting-up-linux
|
|
packages: libwebkit2gtk-4.0-dev build-essential curl wget libssl-dev libgtk-3-dev libayatana-appindicator3-dev librsvg2-dev
|
|
|
|
- name: Build tauri
|
|
run: |
|
|
pnpm tauri build
|
|
|
|
- name: Test rust
|
|
working-directory: src-tauri
|
|
run: |
|
|
cargo test
|