Skip to content

Commit

Permalink
Merge pull request #28 from jwhb/consolidate-actions
Browse files Browse the repository at this point in the history
Consolidate rust-fmt into rust workflow
  • Loading branch information
jwhb authored Mar 17, 2024
2 parents 487e89a + c0a4fd6 commit 9c20b72
Show file tree
Hide file tree
Showing 2 changed files with 33 additions and 29 deletions.
18 changes: 0 additions & 18 deletions .github/workflows/rust-fmt.yml

This file was deleted.

44 changes: 33 additions & 11 deletions .github/workflows/rust.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,17 +13,39 @@ env:
RUSTFLAGS: "-Dwarnings"

jobs:
fmt:
name: Rustfmt
runs-on: ubuntu-latest
steps:
- name: Checkout repo
uses: actions/checkout@v4
- name: Install Rust nightly toolchain with clippy
uses: dtolnay/rust-toolchain@nightly
with:
components: rustfmt
- name: Run Rustfmt
run: cargo fmt -- --check
clippy:
name: Clippy
runs-on: ubuntu-latest
steps:
- name: Checkout repo
uses: actions/checkout@v4
- name: Install Rust nightly toolchain with clippy
uses: dtolnay/rust-toolchain@nightly
with:
components: clippy
- name: Run Clippy
run: cargo clippy --all-targets --all-features
build:

name: Rust Build & Test
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v4
- name: Run Clippy
run: cargo clippy --all-targets --all-features
- name: Build
run: cargo build --verbose
- name: Run tests
run: cargo test --verbose
- name: Run tests (rootful)
run: sudo -E env "PATH=$PATH" bash tests/run_nft_tests.sh
- name: Checkout repo
uses: actions/checkout@v4
- name: Build
run: cargo build --verbose
- name: Run tests
run: cargo test --verbose
- name: Run tests (rootful)
run: sudo -E env "PATH=$PATH" bash tests/run_nft_tests.sh

0 comments on commit 9c20b72

Please sign in to comment.