mirror of
https://github.com/cloud-hypervisor/cloud-hypervisor.git
synced 2026-08-05 02:19:16 +00:00
tests: Switch to launching by command
Launch the test binary by command rather than using using the vmm layer. This makes it easier to manage the running VM as you can explicitly kill it. Also switch to using credibility for the tests which catches assertions and continues with subsequent commands and reports the issues at the end. This means it is possible to cleanup even on failed test runs. Signed-off-by: Rob Bradford <robert.bradford@intel.com>
This commit is contained in:
@@ -28,8 +28,8 @@ rm /tmp/cloudinit.img
|
||||
mkdosfs -n config-2 -C /tmp/cloudinit.img 8192
|
||||
mcopy -oi /tmp/cloudinit.img -s test_data/cloud-init/openstack ::
|
||||
|
||||
cargo test --features "integration_tests" --no-run
|
||||
find target/debug/deps/ -name cloud_hypervisor* | xargs -n1 sudo setcap cap_net_admin+ep
|
||||
cargo build
|
||||
sudo setcap cap_net_admin+ep target/debug/cloud-hypervisor
|
||||
|
||||
# Tests must be executed serially for now as they have a hardcoded IP address
|
||||
cargo test --features "integration_tests" -- --test-threads=1
|
||||
Reference in New Issue
Block a user