[Libvirt-cim] [PATCH] [TEST] Fix VSMS - 05_destroysystem_neg.py to work for both Pegasus and sfcb

Kaitlin Rupert kaitlin at linux.vnet.ibm.com
Tue Aug 12 17:46:03 UTC 2008


Dan Smith wrote:
> GY> +    cmd = "lsof -P -i:5988 | grep sfcbd"
> GY> +    rc, out = utils.run_remote(options.ip, cmd)
> 
> -1 on this one too.
> 
> 

Daisy, changing the error description from 'CIM_ERR_FAILED: Unable to 
retrieve domain name.' to 'Unable to retrieve domain name.' will work.

Instead of:

if err_no == exp_value['rc'] and err_desc == exp_value['desc']:

You can do something like:

if err_no == exp_value['rc'] and err_desc.find(exp_value['desc']) >= 0:

You can look at 
suites/libvirt-cim/cimtest/ResourceAllocationFromPool/04_reverse_errs.py 
- this test uses find on the error descriptions.

For this test, since the provider returns the same error code for both 
errors, so I think checking the error description is needed.
-- 
Kaitlin Rupert
IBM Linux Technology Center
kaitlin at linux.vnet.ibm.com




More information about the Libvirt-cim mailing list