-
Notifications
You must be signed in to change notification settings - Fork 1
41 lines (33 loc) · 884 Bytes
/
tests.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
name: Code Quality
on:
push:
workflow_dispatch:
env:
CARGO_TERM_COLOR: always
stage: prod
jobs:
build:
runs-on: ubuntu-latest
environment: PROD
env:
CARGO_SERVER_SSL_CA: "Code-Quality-Test-CA"
CARGO_SERVER_SSL_CERT: "Code-Quality-Test-Cert"
CARGO_SERVER_SSL_KEY: "Code-Quality-Test-Key"
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Install Rust toolchain and components
uses: dtolnay/rust-toolchain@stable
with:
toolchain: stable
components: rustfmt, clippy
- name: Setup Cache
uses: Swatinem/rust-cache@v2
- name: Create empty .env file
run: touch .env
- name: Build and Test
run: |
cargo build --verbose
cargo test --verbose
cargo clippy -- -D warnings
cargo fmt -- --check