
Sharad Mishra wrote:
Sharad Mishra wrote:
# HG changeset patch # User Sharad Mishra <snmishra@us.ibm.com> # Date 1268161766 28800 # Node ID 12a2efa271d73ef7ed8d88bb27b39cce2505716a # Parent 3655b03ada11d9e99a1d10b97aaa7cdb737fc493 [TEST] Add check to verify StorageVolume InstanceID.
This test verifies that the InstanceID of StorageVolume is not dependent on the pool path in RASD. Rather it is set by virStorageVolGetPath.
Signed-off-by: Sharad Mishra <snmishra@us.ibm.com>
diff -r 3655b03ada11 -r 12a2efa271d7 suites/libvirt-cim/cimtest/ ResourcePoolConfigurationService/10_create_storagevolume.py --- a/suites/libvirt-cim/cimtest/ResourcePoolConfigurationService/ 10_create_storagevolume.py Thu Jan 28 14:00:59 2010 -0800 +++ b/suites/libvirt-cim/cimtest/ResourcePoolConfigurationService/ 10_create_storagevolume.py Tue Mar 09 11:09:26 2010 -0800 @@ -236,10 +236,15 @@ dp_inst_id, exp_vol_path)
+ if res[1]['Resource']['InstanceID'] != exp_vol_path: + status = FAIL + else: + status = PASS
This check should be done after the call to rpcs_conn.CreateResourceInPool() and res[0] != PASS.
Above code lines are after call to CreateResourceInPool and checking for res[0].
Sorry for late reply!! I meant to use it immediately after the call to the CreateResourceInPool(). Currently, you are using it after the call to verify_vol() and verify_template_rasd_exists which makes it little difficult to follow where the res would come from.
Also, include some debug messages when the match fails.
Agreed, I will do that in next revision of this patch.
-Sharad
ret = cleanup_pool_vol(server, virt, pool_name, clean_pool, exp_vol_path) if res[0] == PASS and found == 1 and \ - ret == PASS and stovol_status == PASS: + ret == PASS and stovol_status == PASS and \ + status == PASS: status = PASS else: return FAIL
_______________________________________________ Libvirt-cim mailing list Libvirt-cim@redhat.com https://www.redhat.com/mailman/listinfo/libvirt-cim
-- Thanks and Regards, Deepti B. Kalakeri IBM Linux Technology Center deeptik@linux.vnet.ibm.com
_______________________________________________ Libvirt-cim mailing list Libvirt-cim@redhat.com https://www.redhat.com/mailman/listinfo/libvirt-cim
------------------------------------------------------------------------
_______________________________________________ Libvirt-cim mailing list Libvirt-cim@redhat.com https://www.redhat.com/mailman/listinfo/libvirt-cim
-- Thanks and Regards, Deepti B. Kalakeri IBM Linux Technology Center deeptik@linux.vnet.ibm.com