# HG changeset patch
# User Deepti B. Kalakeri <deeptik(a)linux.vnet.ibm.com>
# Date 1210163663 25200
# Node ID 88d20825a9ba6dd3d070e02f698a7846b7e3a2c8
# Parent f41c618f3d5ba81d0588440b1a62e8916dc9d0a7
[TEST] #2 Modifying common_util.py to use appropriate diskpool conf file.
Used diskpoolconf_rev instead of libvirtcim_rev.
Signed-off-by: Deepti B. Kalakeri <deeptik(a)linux.vnet.ibm.com>
diff -r f41c618f3d5b -r 88d20825a9ba suites/libvirt-cim/lib/XenKvmLib/common_util.py
--- a/suites/libvirt-cim/lib/XenKvmLib/common_util.py Tue May 06 23:20:30 2008 -0700
+++ b/suites/libvirt-cim/lib/XenKvmLib/common_util.py Wed May 07 05:34:23 2008 -0700
@@ -32,9 +32,16 @@ from XenKvmLib.classes import get_typed_
from XenKvmLib.classes import get_typed_class
from CimTest.Globals import logger, log_param, CIM_ERROR_ENUMERATE
from CimTest.ReturnCodes import PASS, FAIL, XFAIL_RC
+from XenKvmLib.const import CIM_REV
test_dpath = "foo"
-disk_file = '/tmp/diskpool.conf'
+diskpoolconf_rev = 558
+
+if CIM_REV < diskpoolconf_rev:
+ disk_file = '/tmp/diskpool.conf'
+else:
+ disk_file = '/etc/libvirt/diskpool.conf'
+
back_disk_file = disk_file + "." + "backup"
def print_field_error(fieldname, ret_value, exp_value):
@@ -245,6 +252,7 @@ def conf_file():
Creating diskpool.conf file.
"""
status = PASS
+ logger.info("Disk conf file : %s", disk_file)
try:
f = open(disk_file, 'w')
f.write('%s %s' % (test_dpath, '/'))
Show replies by date