On 10/11/2013 07:09 AM, Viktor Mihajlovski wrote:
The test domains are now defined with a ConsoleRASD if the
tested libvirt-cim does support those. A few testcases had
to be adjusted to properly handle the newly encountered instances
and associations.
Signed-off-by: Viktor Mihajlovski <mihajlov(a)linux.vnet.ibm.com>
<...snip...>
diff --git a/suites/libvirt-cim/lib/XenKvmLib/vxml.py
b/suites/libvirt-cim/lib/XenKvmLib/vxml.py
index 74c4f23..9489a5c 100644
--- a/suites/libvirt-cim/lib/XenKvmLib/vxml.py
+++ b/suites/libvirt-cim/lib/XenKvmLib/vxml.py
@@ -50,9 +50,11 @@ from CimTest.ReturnCodes import SKIP, PASS, FAIL
from XenKvmLib.classes import virt_types, get_typed_class
from XenKvmLib.enumclass import GetInstance
from XenKvmLib.const import get_provider_version
+from XenKvmLib.xm_virt_util import host_cpu_model
vsms_graphics_sup = 763
vsms_inputdev_sup = 771
+vsms_console_sup = 1276
class XMLClass:
xml_string = ""
@@ -598,7 +600,8 @@ class VirtCIM:
def __init__(self, virt, dom_name, uuid, pae, acpi, apic, disk_dev,
disk_source, net_type, net_name, net_mac, vcpus, mem,
mem_allocunits, emu_type, grstype, ip,
- is_ipv6_only, port_num, kmap, irstype, btype, vnc_passwd):
+ is_ipv6_only, port_num, kmap, irstype, btype, vnc_passwd,
+ con_source_type, con_target_type):
self.virt = virt
self.domain_name = dom_name
self.err_rc = None
@@ -623,6 +626,9 @@ class VirtCIM:
ipv6_flag=is_ipv6_only,
lport=port_num, keymap=kmap,
vnc_passwd=vnc_passwd)
+ self.casd = vsms.get_casd_class(virt)(name=dom_name,
+ source_type=con_source_type,
+ target_type=con_target_type)
self.masd = vsms.get_masd_class(virt)(megabytes=mem,
mallocunits=mem_allocunits,
name=dom_name)
@@ -655,9 +661,14 @@ class VirtCIM:
res_settings.append(str(self.gasd))
if curr_cim_rev >= vsms_inputdev_sup:
- if self.iasd is not None:
+ if self.iasd is not None and \
+ not str(host_cpu_model(ip, self.virt)).startswith('s390'):
res_settings.append(str(self.iasd))
+ if curr_cim_rev >= vsms_console_sup:
+ if ref_conf is None and self.casd is not None:
+ res_settings.append(str(self.casd))
+
I've been working on applying the "next set" of Xu Wang's fixes and
found that by just adding the four core XenKvmLib/*.py files to a test
branch I could core FilterList 03_create.py test rather reliably until I
commented out the above 3 lines.
The first change applied that caused the failure was the writing of the
console xml (#22 in the series).
The core was because for some reason the dumping of the xml didn't find
the "<filterref>" tag and thus the call to "filterref =
test.libvirt_applied_filter_lists(domain_name)[0]" would have an index
out of range exception.
Also a number of the VirtualSystemManagementService and VSSD tests
failed with the "Only the first console can be a serial port..." message.
Unfortunately I missed the notification that the system I had borrowed
had timed out its lease and thus I've lost usage for a bit. However, I
do know without this particular patch, the other changes did run through
cimtest.
I'm going to try and revive the ability to run on my own f19 system, I
have to find a tog-pegasus that works for me....
John