Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: add nightly minimum dependencies test #55

Merged
merged 1 commit into from
Dec 20, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
29 changes: 28 additions & 1 deletion .github/workflows/bvt.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ name: BVT
on: [pull_request]
jobs:
bvt:
name: BVT
name: BVT (stable)
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
Expand All @@ -16,5 +16,32 @@ jobs:
run: make clippy
- name: Build
run: make tokio_vsock
- name: Build all features
run: make tokio_vsock_all_features
- name: Build test_server
run: make test_server
bvt-nightly:
name: BVT (nightly)
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: install dependencies
run: |
rustup default nightly
rustup target add x86_64-unknown-linux-musl
rustup component add rustfmt clippy
- name: Format Check
run: make fmt
- name: Clippy Check
run: make clippy
- name: Build
run: make tokio_vsock
- name: Build all features
run: make tokio_vsock_all_features
- name: Build test_server
run: make test_server
- name: Build (min-deps)
run: |
# we need to select the minimum dependencies so remove previously selected versions
rm Cargo.lock
make tokio_vsock_min_deps
7 changes: 4 additions & 3 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,10 @@ exclude = ["test_fixture"]
[dependencies]
bytes = "1.3.0"
futures = "0.3"
libc = "0.2.138"
libc = "0.2.158"
vsock = "0.5.1"
tokio = { version = "1", features = ["net", "sync"] }
# Keep version in sync with [dev-dependencies]
tokio = { version = "1.34", features = ["net", "sync"] }
tonic05 = { package = "tonic", version = "0.5", optional = true }
tonic06 = { package = "tonic", version = "0.6", optional = true }
tonic07 = { package = "tonic", version = "0.7", optional = true }
Expand All @@ -28,7 +29,7 @@ tonic012 = { package = "tonic", version = "0.12", optional = true }
[dev-dependencies]
sha2 = "0.10.6"
rand = "0.8.5"
tokio = { version = "1", features = ["macros", "rt", "io-util"] }
tokio = { version = "1.34", features = ["macros", "rt", "io-util"] }
Tim-Zhang marked this conversation as resolved.
Show resolved Hide resolved

[package.metadata.docs.rs]
all-features = true
Expand Down
6 changes: 6 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,12 @@ clean:
tokio_vsock: $(SRCS)
cargo build --lib

tokio_vsock_all_features: $(SRCS)
cargo build --lib --all-features

tokio_vsock_min_deps: $(SRCS)
cargo build --lib --all-features -Z direct-minimal-versions

test_server: tokio_vsock test_server/src/main.rs
cargo build --manifest-path=test_server/Cargo.toml

Expand Down
Loading