mirror of
https://github.com/cloud-hypervisor/cloud-hypervisor.git
synced 2025-02-21 19:02:30 +00:00
scripts: Remove unused "cargo" testing script
These are never run by the CI and is inconsistent with the way we build test which is specified inside the .github workflows. Signed-off-by: Rob Bradford <robert.bradford@intel.com>
This commit is contained in:
parent
3c9e97ce00
commit
6eb47bdb03
@ -183,10 +183,9 @@ cmd_help() {
|
||||
echo " --volumes Hash separated volumes to be exported. Example --volumes /mnt:/mnt#/myvol:/myvol"
|
||||
echo " --hypervisor Underlying hypervisor. Options kvm, mshv"
|
||||
echo ""
|
||||
echo " tests [--unit|--cargo|--all] [--libc musl|gnu] [-- [<test scripts args>] [-- [<test binary args>]]] "
|
||||
echo " tests [<test type (see below)>] [--libc musl|gnu] [-- [<test scripts args>] [-- [<test binary args>]]] "
|
||||
echo " Run the Cloud Hypervisor tests."
|
||||
echo " --unit Run the unit tests."
|
||||
echo " --cargo Run the cargo tests."
|
||||
echo " --integration Run the integration tests."
|
||||
echo " --integration-sgx Run the SGX integration tests."
|
||||
echo " --integration-vfio Run the VFIO integration tests."
|
||||
@ -314,7 +313,6 @@ cmd_clean() {
|
||||
|
||||
cmd_tests() {
|
||||
unit=false
|
||||
cargo=false
|
||||
integration=false
|
||||
integration_sgx=false
|
||||
integration_vfio=false
|
||||
@ -332,7 +330,6 @@ cmd_tests() {
|
||||
exit 1
|
||||
} ;;
|
||||
"--unit") { unit=true; } ;;
|
||||
"--cargo") { cargo=true; } ;;
|
||||
"--integration") { integration=true; } ;;
|
||||
"--integration-sgx") { integration_sgx=true; } ;;
|
||||
"--integration-vfio") { integration_vfio=true; } ;;
|
||||
@ -398,16 +395,6 @@ cmd_tests() {
|
||||
./scripts/run_unit_tests.sh "$@" || fix_dir_perms $? || exit $?
|
||||
fi
|
||||
|
||||
if [ "$cargo" = true ]; then
|
||||
say "Running cargo tests..."
|
||||
$DOCKER_RUNTIME run \
|
||||
--workdir "$CTR_CLH_ROOT_DIR" \
|
||||
--rm \
|
||||
--volume "$CLH_ROOT_DIR:$CTR_CLH_ROOT_DIR" $exported_volumes \
|
||||
"$CTR_IMAGE" \
|
||||
./scripts/run_cargo_tests.sh "$@" || fix_dir_perms $? || exit $?
|
||||
fi
|
||||
|
||||
if [ "$integration" = true ]; then
|
||||
say "Running integration tests for $target..."
|
||||
$DOCKER_RUNTIME run \
|
||||
|
@ -1,26 +0,0 @@
|
||||
#!/bin/bash
|
||||
set -e
|
||||
set -x
|
||||
|
||||
source $HOME/.cargo/env
|
||||
source $(dirname "$0")/test-util.sh
|
||||
|
||||
process_common_args "$@"
|
||||
|
||||
# Install cargo components
|
||||
time rustup component add clippy
|
||||
time rustup component add rustfmt
|
||||
time which cargo-audit || cargo install cargo-audit
|
||||
|
||||
# Run cargo builds and checks
|
||||
time cargo clippy --all-targets --all-features -- -D warnings
|
||||
time cargo rustc --bin cloud-hypervisor -- -D warnings
|
||||
time cargo rustc -p vhost_user_net --bin vhost_user_net -- -D warnings
|
||||
time cargo test
|
||||
time cargo audit
|
||||
time cargo clippy --all-targets --no-default-features --features "acpi,$hypervisor" -- -D warnings
|
||||
time cargo rustc --bin cloud-hypervisor --no-default-features --features "acpi,$hypervisor" -- -D warnings
|
||||
time cargo clippy --all-targets --no-default-features --features "$hypervisor" -- -D warnings
|
||||
time cargo rustc --bin cloud-hypervisor --no-default-features --features "$hypervisor" -- -D warnings
|
||||
time cargo fmt -- --check
|
||||
time cargo build --all --release
|
Loading…
x
Reference in New Issue
Block a user