-
Notifications
You must be signed in to change notification settings - Fork 13
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
aea3bd4
commit 08f069a
Showing
4 changed files
with
69 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,50 @@ | ||
--- | ||
name: Builds unit test binary and run unit tests, runs static rust code analysis and code formatting | ||
|
||
on: | ||
push: | ||
branches: | ||
- main | ||
pull_request: | ||
branches: | ||
- main | ||
workflow_dispatch: | ||
|
||
|
||
jobs: | ||
main: | ||
name: Run check, test and lints | ||
runs-on: [self-hosted, Linux, X64, large] | ||
env: | ||
CARGO_INCREMENTAL: 0 | ||
RUSTC_WRAPPER: sccache | ||
steps: | ||
- name: Checkout Source code | ||
uses: actions/checkout@v3 | ||
|
||
- name: Install Rust Toolchain | ||
uses: Cardinal-Cryptography/github-actions/install-rust-toolchain@v1 | ||
with: | ||
targets: wasm32-unknown-unknown | ||
components: clippy rustfmt | ||
|
||
- name: Run Format Checks | ||
uses: actions-rs/cargo@v1 | ||
with: | ||
command: fmt | ||
args: --all | ||
|
||
- name: Run Linter | ||
uses: actions-rs/cargo@v1 | ||
env: | ||
# https://github.com/mozilla/sccache/issues/966 | ||
RUSTC_WRAPPER: "" | ||
RUSTC_WORKSPACE_WRAPPER: sccache | ||
with: | ||
command: clippy | ||
args: --all-targets -- --no-deps -D warnings | ||
|
||
- name: Run Unit Test Suite | ||
uses: actions-rs/cargo@v1 | ||
with: | ||
command: test |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters