mirror of
https://github.com/cloud-hypervisor/cloud-hypervisor.git
synced 2025-01-03 11:25:20 +00:00
tests: Enable virtio-vsock testing with virtio-mmio transport
As compiling without acpi (implied by mmio) means that the VM will terminate on i8042 reset we cannot test the reboot. Signed-off-by: Rob Bradford <robert.bradford@intel.com>
This commit is contained in:
parent
bb6b738c0d
commit
6161d3bef8
@ -1791,6 +1791,8 @@ mod tests {
|
|||||||
// Validate vsock works as expected.
|
// Validate vsock works as expected.
|
||||||
guest.check_vsock(socket.as_str());
|
guest.check_vsock(socket.as_str());
|
||||||
|
|
||||||
|
#[cfg(not(feature = "mmio"))]
|
||||||
|
{
|
||||||
let reboot_count = guest
|
let reboot_count = guest
|
||||||
.ssh_command("sudo journalctl | grep -c -- \"-- Reboot --\"")
|
.ssh_command("sudo journalctl | grep -c -- \"-- Reboot --\"")
|
||||||
.unwrap_or_default()
|
.unwrap_or_default()
|
||||||
@ -1812,7 +1814,7 @@ mod tests {
|
|||||||
|
|
||||||
// Validate vsock still works after a reboot.
|
// Validate vsock still works after a reboot.
|
||||||
guest.check_vsock(socket.as_str());
|
guest.check_vsock(socket.as_str());
|
||||||
|
}
|
||||||
if hotplug {
|
if hotplug {
|
||||||
aver!(
|
aver!(
|
||||||
tb,
|
tb,
|
||||||
@ -3501,7 +3503,7 @@ mod tests {
|
|||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
#[cfg_attr(not(feature = "mmio"), test)]
|
#[test]
|
||||||
fn test_virtio_vsock() {
|
fn test_virtio_vsock() {
|
||||||
_test_virtio_vsock(false)
|
_test_virtio_vsock(false)
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user