mirror of
https://github.com/TECHNOFAB11/jwt-authorizer.git
synced 2025-12-12 16:10:06 +01:00
build: ci
This commit is contained in:
parent
3d8b5a7f46
commit
1579676948
1 changed files with 71 additions and 0 deletions
71
.github/workflows/ci.yml
vendored
Normal file
71
.github/workflows/ci.yml
vendored
Normal file
|
|
@ -0,0 +1,71 @@
|
||||||
|
name: ci
|
||||||
|
on:
|
||||||
|
pull_request:
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
style:
|
||||||
|
name: Format
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v3
|
||||||
|
- name: Install Rust
|
||||||
|
uses: actions-rs/toolchain@v1
|
||||||
|
with:
|
||||||
|
profile: minimal
|
||||||
|
toolchain: stable
|
||||||
|
override: true
|
||||||
|
components: rustfmt
|
||||||
|
|
||||||
|
- name: Check format
|
||||||
|
uses: actions-rs/cargo@v1
|
||||||
|
with:
|
||||||
|
command: fmt
|
||||||
|
args: -- --check
|
||||||
|
|
||||||
|
clippy:
|
||||||
|
name: Clippy
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v3
|
||||||
|
- uses: actions-rs/toolchain@v1
|
||||||
|
with:
|
||||||
|
profile: minimal
|
||||||
|
toolchain: stable
|
||||||
|
override: true
|
||||||
|
components: clippy
|
||||||
|
- uses: actions-rs/cargo@v1
|
||||||
|
with:
|
||||||
|
command: clippy
|
||||||
|
args: --all-targets --all-features -- -D warnings
|
||||||
|
|
||||||
|
tests:
|
||||||
|
name: Tests
|
||||||
|
runs-on: ${{ matrix.os }}
|
||||||
|
strategy:
|
||||||
|
matrix:
|
||||||
|
build: [pinned, stable, nightly]
|
||||||
|
include:
|
||||||
|
- build: pinned
|
||||||
|
os: ubuntu-20.04
|
||||||
|
rust: 1.65.0
|
||||||
|
- build: stable
|
||||||
|
os: ubuntu-20.04
|
||||||
|
rust: stable
|
||||||
|
- build: nightly
|
||||||
|
os: ubuntu-20.04
|
||||||
|
rust: nightly
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v3
|
||||||
|
- name: Install Rust
|
||||||
|
uses: hecrj/setup-rust-action@v1
|
||||||
|
with:
|
||||||
|
rust-version: ${{ matrix.rust }}
|
||||||
|
|
||||||
|
- name: Build System Info
|
||||||
|
run: rustc --version
|
||||||
|
|
||||||
|
- name: Run tests default features
|
||||||
|
run: cargo test
|
||||||
|
|
||||||
|
- name: Run tests no features
|
||||||
|
run: cargo test --no-default-features
|
||||||
Loading…
Add table
Add a link
Reference in a new issue