Skip to content

Commit

Permalink
Merge pull request #321 from systemaccounting/320-httpclient-crate
Browse files Browse the repository at this point in the history
320 httpclient crate
  • Loading branch information
mxfactorial authored Jan 9, 2024
2 parents 79a107a + fc5608e commit bdf2c2e
Show file tree
Hide file tree
Showing 10 changed files with 2,021 additions and 117 deletions.
19 changes: 14 additions & 5 deletions .github/workflows/dev-crates.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -20,14 +20,12 @@ jobs:
- uses: taiki-e/install-action@nextest
- name: crates/types lint
run: |
cargo fmt -- --check
cargo clippy -- -Dwarnings
working-directory: crates/types
cargo fmt -p pg -p types -p httpclient -- --check
cargo clippy -p pg -p types -p httpclient -- -Dwarnings
- name: install cargo-llvm-cov
uses: taiki-e/install-action@cargo-llvm-cov
- name: crates/types unit tests
run: cargo test
working-directory: crates/types
run: cargo test -p pg -p types -p httpclient
- name: crates/types coverage report
run: |
make rust-coverage RUST_PKG=types
Expand All @@ -45,6 +43,17 @@ jobs:
echo "MIN_CODE_COV=$(yq .crates.pg.min_code_cov project.yaml)" >> $GITHUB_ENV
echo "CURR_CODE_COV=$(make rust-coverage-percent RUST_PKG=pg)" >> $GITHUB_ENV
- name: fail crates/pg coverage under ${{ env.MIN_CODE_COV }}%
run: |
if [[ ${{ env.CURR_CODE_COV }} -lt ${{ env.MIN_CODE_COV }} ]]; then
echo 'coverage dropped below ${{ env.MIN_CODE_COV }}: ${{ env.CURR_CODE_COV }}%'
exit 1
fi
- name: crates/httpcrate coverage report
run: |
make rust-coverage RUST_PKG=httpcrate
echo "MIN_CODE_COV=$(yq .crates.httpcrate.min_code_cov project.yaml)" >> $GITHUB_ENV
echo "CURR_CODE_COV=$(make rust-coverage-percent RUST_PKG=httpcrate)" >> $GITHUB_ENV
- name: fail crates/httpcrate coverage under ${{ env.MIN_CODE_COV }}%
run: |
if [[ ${{ env.CURR_CODE_COV }} -lt ${{ env.MIN_CODE_COV }} ]]; then
echo 'coverage dropped below ${{ env.MIN_CODE_COV }}: ${{ env.CURR_CODE_COV }}%'
Expand Down
Loading

0 comments on commit bdf2c2e

Please sign in to comment.