-
Notifications
You must be signed in to change notification settings - Fork 31
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add CI build, test and lint step for httpd
- Loading branch information
1 parent
a590ee8
commit d8e9f1c
Showing
1 changed file
with
59 additions
and
0 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,59 @@ | ||
name: check-httpd-server | ||
on: push | ||
|
||
jobs: | ||
test: | ||
name: Build & Test | ||
runs-on: ubuntu-latest | ||
defaults: | ||
run: | ||
working-directory: ./httpd-server | ||
steps: | ||
- uses: actions/checkout@v4 | ||
- uses: dtolnay/rust-toolchain@stable | ||
id: rust-toolchain | ||
- name: Cache cargo registry | ||
uses: actions/cache@v1 | ||
with: | ||
path: ~/.cargo/registry | ||
key: ${{ runner.os }}-cargo-registry-${{steps.rust-toolchain.outputs.cachekey}} | ||
- name: Build | ||
run: cargo build --all-features | ||
- name: Run tests | ||
run: cargo test --all-features | ||
docs: | ||
name: Docs | ||
runs-on: ubuntu-latest | ||
defaults: | ||
run: | ||
working-directory: ./httpd-server | ||
steps: | ||
- uses: actions/checkout@v4 | ||
- uses: dtolnay/rust-toolchain@stable | ||
id: rust-toolchain | ||
- name: Cache cargo registry | ||
uses: actions/cache@v1 | ||
with: | ||
path: ~/.cargo/registry | ||
key: ${{ runner.os }}-cargo-registry-${{steps.rust-toolchain.outputs.cachekey}} | ||
- name: Docs | ||
run: cargo doc --all --all-features | ||
lint: | ||
name: Lint | ||
runs-on: ubuntu-latest | ||
defaults: | ||
run: | ||
working-directory: ./httpd-server | ||
steps: | ||
- uses: actions/checkout@v4 | ||
- uses: dtolnay/rust-toolchain@stable | ||
id: rust-toolchain | ||
- name: Cache cargo registry | ||
uses: actions/cache@v1 | ||
with: | ||
path: ~/.cargo/registry | ||
key: ${{ runner.os }}-cargo-registry-${{steps.rust-toolchain.outputs.cachekey}} | ||
- name: Run clippy | ||
run: cargo clippy --all --tests | ||
- name: Check formatting | ||
run: cargo fmt --all --check |