Skip to content

Commit

Permalink
chore(ci): add sync tests into ci
Browse files Browse the repository at this point in the history
  • Loading branch information
fundon committed Jan 1, 2024
1 parent aa4733e commit 58ed58e
Show file tree
Hide file tree
Showing 3 changed files with 18 additions and 4 deletions.
5 changes: 3 additions & 2 deletions .github/workflows/CI.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,8 @@ jobs:
steps:
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@nightly
- run: cargo test --all --verbose
- run: cargo test --test form-data --test hyper-body
- run: cargo test --test tiny-body --features="sync" --no-default-features

clippy:
name: Clippy
Expand All @@ -44,7 +45,7 @@ jobs:
steps:
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@stable
- run: cargo fmt --all -- --check
- run: cargo fmt --all-features -- --check

docs:
name: Doc
Expand Down
15 changes: 15 additions & 0 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -66,3 +66,18 @@ path = "examples/hyper.rs"
name = "tiny_http"
path = "examples/tiny_http.rs"
required-features = ["sync"]

[[test]]
name = "form-data"
path = "tests/form-data.rs"
required-features = ["async"]

[[test]]
name = "hyper-body"
path = "tests/hyper-body.rs"
required-features = ["async"]

[[test]]
name = "tiny-body"
path = "tests/tiny-body.rs"
required-features = ["sync"]
2 changes: 0 additions & 2 deletions tests/tiny-body.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,6 @@
//! RUST_LOG=trace cargo test --test tiny-body --no-default-features --features="sync" -- --nocapture
//! ```
#![cfg(feature = "sync")]

use std::{fs::File, io::Read, str::FromStr};

use anyhow::Result;
Expand Down

0 comments on commit 58ed58e

Please # to comment.