[Libvirt-cim] [PATCH 2 of 3] [TEST] Add new tc to verify the DeleteResourceInPool()
Kaitlin Rupert
kaitlin at linux.vnet.ibm.com
Thu Sep 10 20:35:16 UTC 2009
> + at do_main(platform_sup)
> +def main():
> + options = main.options
> + server = options.ip
> + virt = options.virt
> +
> + libvirt_ver = virsh_version(server, virt)
> + cim_rev, changeset = get_provider_version(virt, server)
> + if libvirt_ver < "0.4.1" and cim_rev < libvirt_rasd_spool_del_changes:
> + logger.info("Storage Volume deletion support is available with Libvirt"
> + "version >= 0.4.1 and Libvirt-CIM rev '%s'",
> + libvirt_rasd_spool_del_changes)
> + return SKIP
> +
> + dp_cn = "DiskPool"
> + exp_vol_path = "%s/%s" % (pool_attr['Path'], vol_name)
> +
> + # For now the test case support only the deletion of dir type based
> + # vol, we can extend dp_types to include netfs etc .....
> + dp_types = { "DISK_POOL_DIR" : DIR_POOL }
> +
> + for pool_name, pool_type in dp_types.iteritems():
> + status = FAIL
> + res = del_res = [FAIL]
> + clean_pool=True
> + try:
> + if pool_type == DIR_POOL:
> + pool_name = default_pool_name
> + clean_pool=False
Need spaces here around the = sign.
--
Kaitlin Rupert
IBM Linux Technology Center
kaitlin at linux.vnet.ibm.com
More information about the Libvirt-cim
mailing list