mirror of
https://github.com/xcat2/xcat-core.git
synced 2026-10-22 23:58:13 +00:00
fc6668d972
kvm_guest_arch.t cut build_xmldesc and five other routines out of kvm.pm with a regex and ran them with eval in a scratch package. The test passed when kvm.pm changed in a way the regex did not see, and it failed when kvm.pm was reformatted. The test now loads kvm.pm with require and calls xCAT_plugin::kvm::build_xmldesc and build_diskstruct. Sys::Virt and the monitoring plugin are stubbed in %INC. kvm.pm declares $updatetable, $confdata, $hypconn and $node with our instead of my, so that the test can set them with local. The test sets XCATROOT to the checkout and asserts that no module loads from /opt/xcat. Signed-off-by: Daniel Hilst <392820+dhilst@users.noreply.github.com>