# HG changeset patch
# User Kaitlin Rupert <karupert(a)us.ibm.com>
# Date 1257802470 28800
# Node ID 2489a1776bb628edb70b4586eb6548a4e47a022b
# Parent 9b3156cd8d1a72573531f23cd3e0907d71685c34
[TEST] Fix VSMS 23 to SKIP for old provider sets
The duplicate MAC change was added in revision 929 - this test should skip
if the provider set is older than this.
Signed-off-by: Kaitlin Rupert <karupert(a)us.ibm.com>
diff -r 9b3156cd8d1a -r 2489a1776bb6
suites/libvirt-cim/cimtest/VirtualSystemManagementService/23_verify_duplicate_mac_err.py
---
a/suites/libvirt-cim/cimtest/VirtualSystemManagementService/23_verify_duplicate_mac_err.py Mon
Nov 09 13:24:52 2009 -0800
+++
b/suites/libvirt-cim/cimtest/VirtualSystemManagementService/23_verify_duplicate_mac_err.py Mon
Nov 09 13:34:30 2009 -0800
@@ -29,11 +29,12 @@
from XenKvmLib.vsms import get_vsms_class, get_nasd_class
from XenKvmLib.vxml import get_class
from CimTest.Globals import logger
-from CimTest.ReturnCodes import FAIL, PASS
+from CimTest.ReturnCodes import FAIL, PASS, SKIP
from XenKvmLib.const import default_network_name, do_main
from XenKvmLib.common_util import create_netpool_conf, destroy_netpool
from XenKvmLib.classes import get_typed_class
from XenKvmLib.enumclass import GetInstance, EnumNames
+from XenKvmLib.const import get_provider_version
sup_types = ['Xen', 'KVM', 'XenFV']
default_dom = 'net_domain1'
@@ -44,6 +45,7 @@
exp_rc = CIM_ERR_FAILED
exp_desc = "Conflicting MAC Addresses"
+dup_mac_rev = 929
def cleanup_env(ip, virt, npool_name, cxml):
cxml.cim_destroy(ip)
@@ -72,6 +74,11 @@
def main():
options = main.options
+ rev, changeset = get_provider_version(options.virt, options.ip)
+ if rev < dup_mac_rev:
+ logger.error("Test only valid with provider version > %d",
dup_mac_rev)
+ return SKIP
+
status, net_name = create_netpool_conf(options.ip, options.virt,
use_existing=False,
net_name=npool_name)