Files
wasmtime/.github/workflows/ci.yml
Jakub Konka 5f5f31beab Treat all warnings as errors by default (#161)
* Treat all warnings as errors in the CI

* Build only in release mode
2019-10-31 11:45:42 +01:00

113 lines
2.4 KiB
YAML

name: Continuous Integration
on:
push:
branches:
- master
pull_request:
branches:
- master
jobs:
build_stable:
name: Build stable
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest, macOS-latest, windows-latest]
rust: [stable, 1.37.0]
steps:
- name: Checkout
uses: actions/checkout@v1
- name: Install Rust
uses: actions-rs/toolchain@v1
with:
profile: minimal
toolchain: ${{ matrix.rust }}
override: true
components: rustfmt
- name: Check formatting
uses: actions-rs/cargo@v1
with:
command: fmt
args: --all -- --check
- name: Build
env:
RUSTFLAGS: "-D warnings"
uses: actions-rs/cargo@v1
with:
command: build
args: --release
build_nightly:
name: Build beta & nightly
runs-on: macOS-latest
strategy:
fail-fast: false
matrix:
rust: [beta, nightly]
steps:
- name: Checkout
uses: actions/checkout@v1
- name: Install Rust
uses: actions-rs/toolchain@v1
with:
profile: minimal
toolchain: ${{ matrix.rust }}
override: true
- name: Build
continue-on-error: true
uses: actions-rs/cargo@v1
with:
command: build
args: --release
test:
name: Test
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest, macOS-latest, windows-latest]
rust: [stable, 1.37.0]
steps:
- name: Checkout
uses: actions/checkout@v1
with:
submodules: recursive
- name: Install Rust
uses: actions-rs/toolchain@v1
with:
profile: minimal
toolchain: ${{ matrix.rust }}
target: wasm32-wasi
override: true
- name: Run tests
uses: actions-rs/cargo@v1
with:
command: test
args: --all --features wasm_tests
doc:
name: Doc
runs-on: macOS-latest
steps:
- name: Checkout
uses: actions/checkout@v1
- name: Install Rust
uses: actions-rs/toolchain@v1
with:
profile: minimal
toolchain: stable
override: true
- name: Generate docs
uses: actions-rs/cargo@v1
with:
command: doc
args: --no-deps --all