mirror of
https://github.com/cloud-hypervisor/cloud-hypervisor.git
synced 2024-08-21 07:21:15 +00:00
ci: Enable snapshot/restore integration test
Now that snapshot/restore feature is stable for both virtio-mmio and virtio-pci devices, we re-enable the integration test for validating snapshot/restore does not get broken. Signed-off-by: Sebastien Boeuf <sebastien.boeuf@intel.com>
This commit is contained in:
parent
c566f1f024
commit
9e165c2c17
@ -4242,8 +4242,7 @@ mod tests {
|
|||||||
// One thing to note about this test. The virtio-net device is heavily used
|
// One thing to note about this test. The virtio-net device is heavily used
|
||||||
// through each ssh command. There's no need to perform a dedicated test to
|
// through each ssh command. There's no need to perform a dedicated test to
|
||||||
// verify the migration went well for virtio-net.
|
// verify the migration went well for virtio-net.
|
||||||
#[ignore]
|
#[test]
|
||||||
#[cfg_attr(feature = "mmio", test)]
|
|
||||||
fn test_snapshot_restore() {
|
fn test_snapshot_restore() {
|
||||||
test_block!(tb, "", {
|
test_block!(tb, "", {
|
||||||
let mut clear = ClearDiskConfig::new();
|
let mut clear = ClearDiskConfig::new();
|
||||||
@ -4258,7 +4257,7 @@ mod tests {
|
|||||||
|
|
||||||
let mut child = GuestCommand::new(&guest)
|
let mut child = GuestCommand::new(&guest)
|
||||||
.args(&["--api-socket", &api_socket])
|
.args(&["--api-socket", &api_socket])
|
||||||
.args(&["--cpus", "boot=4"])
|
.args(&["--cpus", "boot=1"])
|
||||||
.args(&["--memory", "size=4G"])
|
.args(&["--memory", "size=4G"])
|
||||||
.args(&["--kernel", kernel_path.to_str().unwrap()])
|
.args(&["--kernel", kernel_path.to_str().unwrap()])
|
||||||
.default_disks()
|
.default_disks()
|
||||||
@ -4271,7 +4270,7 @@ mod tests {
|
|||||||
thread::sleep(std::time::Duration::new(20, 0));
|
thread::sleep(std::time::Duration::new(20, 0));
|
||||||
|
|
||||||
// Check the number of vCPUs
|
// Check the number of vCPUs
|
||||||
aver_eq!(tb, guest.get_cpu_count().unwrap_or_default(), 4);
|
aver_eq!(tb, guest.get_cpu_count().unwrap_or_default(), 1);
|
||||||
// Check the guest RAM
|
// Check the guest RAM
|
||||||
aver!(tb, guest.get_total_memory().unwrap_or_default() > 3_968_000);
|
aver!(tb, guest.get_total_memory().unwrap_or_default() > 3_968_000);
|
||||||
// Check if the block device is readable
|
// Check if the block device is readable
|
||||||
@ -4339,7 +4338,7 @@ mod tests {
|
|||||||
thread::sleep(std::time::Duration::new(10, 0));
|
thread::sleep(std::time::Duration::new(10, 0));
|
||||||
|
|
||||||
// Perform same checks to validate VM has been properly restored
|
// Perform same checks to validate VM has been properly restored
|
||||||
aver_eq!(tb, guest.get_cpu_count().unwrap_or_default(), 4);
|
aver_eq!(tb, guest.get_cpu_count().unwrap_or_default(), 1);
|
||||||
aver!(tb, guest.get_total_memory().unwrap_or_default() > 3_968_000);
|
aver!(tb, guest.get_total_memory().unwrap_or_default() > 3_968_000);
|
||||||
aver!(
|
aver!(
|
||||||
tb,
|
tb,
|
||||||
|
Loading…
Reference in New Issue
Block a user