staging: add custom pipelines to run CI tests

Let's use custom pipelines to run CI tests in the nested worskpace.

We have included all the tests we usually run in the main workspace
(rust-vmm-ci/.buildkite/test_description.json), except for "commit-format"
which also covers commits for staging crates.

Let's add a `staging\coverage_config_x86_64.json` for testing coverage of
crates in staging.

All staging tests have `soft_fail = true` to prevent failures in staging
from affecting the CI of the main workspace.

Closes #478

Signed-off-by: Stefano Garzarella <sgarzare@redhat.com>
This commit is contained in:
Stefano Garzarella 2023-10-17 10:08:13 +02:00 committed by Viresh Kumar
parent eabf93f3d5
commit 994ffe1864
2 changed files with 86 additions and 0 deletions

View File

@ -0,0 +1,81 @@
{
"tests": [
{
"test_name": "staging: build-gnu",
"command": "cd staging && RUSTFLAGS=\"-D warnings\" cargo build --release",
"soft_fail": "true",
"platform": [
"x86_64",
"aarch64"
]
},
{
"test_name": "staging: build-musl",
"command": "cd staging && RUSTFLAGS=\"-D warnings\" cargo build --release --target {target_platform}-unknown-linux-musl",
"soft_fail": "true",
"platform": [
"x86_64",
"aarch64"
]
},
{
"test_name": "staging: style",
"command": "cd staging && cargo fmt --all -- --check --config format_code_in_doc_comments=true"
},
{
"test_name": "staging: unittests-gnu",
"command": "cd staging && cargo test --all-features --workspace",
"soft_fail": "true",
"platform": [
"x86_64",
"aarch64"
]
},
{
"test_name": "staging: unittests-musl",
"command": "cd staging && cargo test --all-features --workspace --target {target_platform}-unknown-linux-musl",
"soft_fail": "true",
"platform": [
"x86_64",
"aarch64"
]
},
{
"test_name": "staging: clippy",
"command": "cd staging && cargo clippy --workspace --bins --examples --benches --all-features --all-targets -- -D warnings -D clippy::undocumented_unsafe_blocks",
"soft_fail": "true",
"platform": [
"x86_64",
"aarch64"
]
},
{
"test_name": "staging: check-warnings",
"command": "cd staging && RUSTFLAGS=\"-D warnings\" cargo check --all-targets --all-features --workspace",
"soft_fail": "true",
"platform": [
"x86_64",
"aarch64"
]
},
{
"test_name": "staging: coverage",
"command": "cd staging && pytest $(find .. -type f -name \"test_coverage.py\")",
"soft_fail": "true",
"docker_plugin": {
"privileged": true
},
"platform": [
"x86_64"
]
},
{
"test_name": "staging: cargo-audit",
"command": "cd staging && cargo audit -q --deny warnings",
"soft_fail": "true",
"platform": [
"x86_64"
]
}
]
}

View File

@ -0,0 +1,5 @@
{
"coverage_score": 7.94,
"exclude_path": "",
"crate_features": ""
}