From 0d8263cba11bd68143c7948c2c7e0178e6f1cdf9 Mon Sep 17 00:00:00 2001 From: Paul Masurel Date: Mon, 31 Jan 2022 16:10:11 +0900 Subject: [PATCH] Using nightly to format --- .github/workflows/test.yml | 18 +++++++++++++++--- Makefile | 3 +++ 2 files changed, 18 insertions(+), 3 deletions(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 885e83915..c0b11b1d3 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -21,10 +21,22 @@ jobs: - name: Install latest nightly to test also against unstable feature flag uses: actions-rs/toolchain@v1 with: - toolchain: stable + toolchain: nightly override: true components: rustfmt + - name: Install latest nightly to test also against unstable feature flag + uses: actions-rs/toolchain@v1 + with: + toolchain: stable + override: true + components: rustfmt, clippy - name: Run tests - run: cargo test --features mmap,brotli-compression,lz4-compression,snappy-compression,failpoints --verbose --workspace + run: cargo +stable test --features mmap,brotli-compression,lz4-compression,snappy-compression,failpoints --verbose --workspace - name: Check Formatting - run: cargo fmt --all -- --check + run: cargo +nightly fmt --all -- --check + - uses: actions-rs/clippy-check@v1 + with: + toolchain: stable + token: ${{ secrets.GITHUB_TOKEN }} + args: --tests + diff --git a/Makefile b/Makefile index 05f0f4447..764d93849 100644 --- a/Makefile +++ b/Makefile @@ -1,3 +1,6 @@ test: echo "Run test only... No examples." cargo test --tests --lib + +fmt: + cargo +nightly fmt --all