mirror of
https://github.com/cloud-hypervisor/cloud-hypervisor.git
synced 2026-08-05 02:19:16 +00:00
Refactor api_create_body() to read cpu_count, kernel_path, and kernel_cmdline from Guest fields instead of taking them as parameters. This makes Guest the single source of truth for VM configuration. Update all call sites in HTTP and DBus API tests to use the new parameterless signature. Switch guest creation to use GuestFactory for consistent 4-CPU configuration. Replace manual CPU and memory assertions with validate_cpu_count() and validate_memory() helpers. Replace thread::sleep with wait_vm_boot() in _test_api_create_boot for proper boot synchronization. Signed-off-by: Muminul Islam <muislam@microsoft.com>