This repository has been archived by the owner on Aug 31, 2023. It is now read-only.
forked from bytecodealliance/wasm-tools
-
Notifications
You must be signed in to change notification settings - Fork 1
99 lines (93 loc) · 3.31 KB
/
main.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
name: CI
on:
push:
branches: [main]
pull_request:
branches: [main]
# Cancel any in-flight jobs for the same PR/branch so there's only one active
# at a time
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
test:
name: Test
runs-on: ${{ matrix.os }}
strategy:
matrix:
build: [stable, beta, nightly, macos, windows]
include:
- build: stable
os: ubuntu-latest
rust: stable
- build: beta
os: ubuntu-latest
rust: beta
- build: nightly
os: ubuntu-latest
rust: nightly
- build: macos
os: macos-latest
rust: stable
- build: windows
os: windows-latest
rust: stable
steps:
- uses: actions/checkout@v2
with:
submodules: true
- name: Install Rust (rustup)
run: rustup update ${{ matrix.rust }} --no-self-update && rustup default ${{ matrix.rust }}
shell: bash
- run: cargo test --all
- run: cargo test -p wasmparser --benches
- run: cargo build --manifest-path crates/wast/Cargo.toml --no-default-features
- run: cargo build --manifest-path crates/wast/Cargo.toml --no-default-features --features wasm-module
- run: cmake -S ${{github.workspace}}/examples -B ${{github.workspace}}/examples/build -DCMAKE_BUILD_TYPE=Release
- run: cmake --build ${{github.workspace}}/examples/build --config Release
rustfmt:
name: Rustfmt
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Install Rust
run: rustup update stable && rustup default stable && rustup component add rustfmt
- run: cargo fmt -- --check
fuzz:
name: Fuzz
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
with:
submodules: true
- name: Install Rust
run: rustup update nightly && rustup default nightly
- run: cargo install cargo-fuzz
- run: cargo fuzz build --dev -s none
- run: cargo fuzz build --dev --features wasmtime -s none
check:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- run: cargo check --benches -p wasm-smith
- run: cargo check --no-default-features
- run: cargo check --no-default-features --features print
- run: cargo check --no-default-features --features parse
- run: cargo check --no-default-features --features validate
- run: cargo check --no-default-features --features smith
- run: cargo check --no-default-features --features shrink
- run: cargo check --no-default-features --features mutate
- run: cargo check --no-default-features --features dump
- run: cargo check --no-default-features --features objdump
- run: cargo check --no-default-features --features strip
- run: cargo check --no-default-features --features compose
- run: cargo check --no-default-features --features demangle
- run: cargo check --no-default-features --features component
- run: cargo check --no-default-features --features metadata
- run: cargo check --no-default-features --features wit-smith
- run: cargo check --no-default-features --features addr2line
doc:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- run: cargo doc --all