test(ci): add workflow #18
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
on: [push, pull_request] | |
name: Test | |
jobs: | |
test: | |
name: Test | |
runs-on: ubuntu-latest | |
steps: | |
- name: Set up Git | |
run: git config --global core.sparseCheckout true | |
- uses: actions/checkout@v3 | |
- name: Get corelib | |
run: git clone -b lucas/multiline_diag https://github.com/0xLucqs/cairo | |
- name: Install toolchain | |
run: rustup show | |
- uses: Swatinem/rust-cache@v2 | |
- name: Run cargo clippy | |
run: cargo clippy -- -D warnings | |
- name: Run cargo test | |
run: CORELIB_PATH="/corelib/corelib/src" cargo test | |
- name: Run cargo fmt | |
run: rustup update nightly && rustup run nightly cargo fmt -- --check |