Since the KVM config system deliver strings for the user, let's make a bit of eval trickery to make the old syntax for the koji method work. Signed-off-by: Lucas Meneghel Rodrigues <lmr@xxxxxxxxxx> --- client/tests/kvm/tests/build.py | 17 ++++++++++------- 1 files changed, 10 insertions(+), 7 deletions(-) diff --git a/client/tests/kvm/tests/build.py b/client/tests/kvm/tests/build.py index d22d59b..789373b 100644 --- a/client/tests/kvm/tests/build.py +++ b/client/tests/kvm/tests/build.py @@ -158,9 +158,11 @@ class KojiInstaller: """ default_koji_cmd = '/usr/bin/koji' default_src_pkg = 'qemu' - default_pkg_list = ['qemu-kvm', 'qemu-kvm-tools'] - default_qemu_bin_paths = ['/usr/bin/qemu-kvm', '/usr/bin/qemu-img'] - default_extra_modules = None + # Since the config file will provide strings, to save some + # comparisons, we're converting the values below to strings. + default_pkg_list = str(['qemu-kvm', 'qemu-kvm-tools']) + default_qemu_bin_paths = str(['/usr/bin/qemu-kvm', '/usr/bin/qemu-img']) + default_extra_modules = str(None) self.koji_cmd = params.get("koji_cmd", default_koji_cmd) @@ -170,9 +172,9 @@ class KojiInstaller: os_dep.command(self.koji_cmd) self.src_pkg = params.get("src_pkg", default_src_pkg) - self.pkg_list = params.get("pkg_list", default_pkg_list) - self.qemu_bin_paths = params.get("qemu_bin_paths", - default_qemu_bin_paths) + self.pkg_list = eval(params.get("pkg_list", default_pkg_list)) + self.qemu_bin_paths = eval(params.get("qemu_bin_paths", + default_qemu_bin_paths)) self.tag = params.get("koji_tag", None) self.build = params.get("koji_build", None) if self.tag and self.build: @@ -192,7 +194,8 @@ class KojiInstaller: self.load_modules = True elif load_modules == 'no': self.load_modules = False - self.extra_modules = params.get("extra_modules", default_extra_modules) + self.extra_modules = eval(params.get("extra_modules", + default_extra_modules)) self.srcdir = test.srcdir self.test_bindir = test.bindir -- 1.6.5.2 -- To unsubscribe from this list: send the line "unsubscribe kvm" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html