2021-04-11 01:09:09 +03:00
|
|
|
# Copyright 2019-2021 Tauri Programme within The Commons Conservancy
|
|
|
|
# SPDX-License-Identifier: Apache-2.0
|
|
|
|
# SPDX-License-Identifier: MIT
|
|
|
|
|
2020-07-15 14:14:11 +03:00
|
|
|
name: test bundler
|
|
|
|
|
|
|
|
on:
|
|
|
|
pull_request:
|
|
|
|
paths:
|
2020-07-16 02:05:07 +03:00
|
|
|
- '.github/workflows/test-bundler.yml'
|
2021-04-12 07:59:25 +03:00
|
|
|
- 'tooling/bundler/**'
|
2020-07-15 14:14:11 +03:00
|
|
|
env:
|
|
|
|
RUST_BACKTRACE: 1
|
|
|
|
|
|
|
|
jobs:
|
|
|
|
build-tauri-bundler:
|
|
|
|
runs-on: ${{ matrix.platform }}
|
|
|
|
|
|
|
|
strategy:
|
|
|
|
fail-fast: false
|
|
|
|
matrix:
|
|
|
|
platform: [ubuntu-latest, macos-latest, windows-latest]
|
|
|
|
|
|
|
|
steps:
|
|
|
|
- uses: actions/checkout@v2
|
|
|
|
- name: install stable
|
|
|
|
uses: actions-rs/toolchain@v1
|
|
|
|
with:
|
|
|
|
toolchain: stable
|
2021-04-05 20:51:17 +03:00
|
|
|
- name: install webkit2gtk (ubuntu only)
|
|
|
|
if: matrix.platform == 'ubuntu-latest'
|
|
|
|
run: |
|
|
|
|
sudo apt-get update
|
|
|
|
sudo apt-get install -y webkit2gtk-4.0
|
2020-07-15 14:14:11 +03:00
|
|
|
- name: test
|
|
|
|
run: |
|
2021-04-12 07:59:25 +03:00
|
|
|
cd ./tooling/bundler
|
2020-07-15 14:14:11 +03:00
|
|
|
cargo test
|
|
|
|
|
|
|
|
clippy-fmt-check:
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
|
|
|
|
steps:
|
|
|
|
- uses: actions/checkout@v2
|
|
|
|
- run: rustup component add clippy
|
2021-04-05 20:51:17 +03:00
|
|
|
- name: install webkit2gtk (ubuntu only)
|
|
|
|
if: matrix.platform == 'ubuntu-latest'
|
|
|
|
run: |
|
|
|
|
sudo apt-get update
|
|
|
|
sudo apt-get install -y webkit2gtk-4.0
|
2020-07-15 14:14:11 +03:00
|
|
|
- name: clippy check
|
|
|
|
uses: actions-rs/clippy-check@v1
|
|
|
|
with:
|
|
|
|
token: ${{ secrets.GITHUB_TOKEN }}
|
2021-04-12 07:59:25 +03:00
|
|
|
args: --manifest-path ./tooling/bundler/Cargo.toml --all-targets -- -D warnings
|
2020-07-15 14:14:11 +03:00
|
|
|
name: bundler
|
|
|
|
- name: install rustfmt
|
|
|
|
uses: actions-rs/toolchain@v1
|
|
|
|
with:
|
|
|
|
profile: minimal
|
|
|
|
toolchain: nightly
|
|
|
|
override: true
|
|
|
|
components: rustfmt
|
|
|
|
- name: fmt check
|
|
|
|
uses: actions-rs/cargo@v1
|
|
|
|
with:
|
|
|
|
command: fmt
|
2021-04-12 07:59:25 +03:00
|
|
|
args: --manifest-path ./tooling/bundler/Cargo.toml --all -- --check
|