Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

kvm.tests: Fix some problems found with pylint

Signed-off-by: Lucas Meneghel Rodrigues <lmr@redhat.com>
  • Loading branch information...
commit 14d7415ce4d807e352856fb6666c70d4b15aa600 1 parent 51854e6
@lmr lmr authored
Showing with 7 additions and 6 deletions.
  1. +7 −6 kvm/tests/cpuflags.py
View
13 kvm/tests/cpuflags.py
@@ -1,5 +1,6 @@
import logging, re, random, os, time, pickle, sys, traceback
from autotest.client.shared import error, utils
+from autotest.client.shared import test as test_module
from virttest import kvm_vm
from virttest import utils_misc, utils_test, aexpect
@@ -317,9 +318,9 @@ def parse_cpu_model():
extra_flags = set([])
return (cpu_model, extra_flags)
- class MiniSubtest(object):
+ class MiniSubtest(test_module.Subtest):
def __new__(cls, *args, **kargs):
- self = super(MiniSubtest, cls).__new__(cls)
+ self = test.Subtest.__new__()
ret = None
if args is None:
args = []
@@ -344,7 +345,8 @@ class Test_temp(MiniSubtest):
def clean(self):
logging.info("cleanup")
if (hasattr(self, "vm")):
- self.vm.destroy(gracefully=False)
+ vm = getattr(self, "vm")
+ vm.destroy(gracefully=False)
# 1) <qemu-kvm-cmd> -cpu ?model
class test_qemu_cpu_model(MiniSubtest):
@@ -704,9 +706,8 @@ def test(self):
class testMultihostMigration(utils_test.MultihostMigration):
def __init__(self, test, params, env):
- super(testMultihostMigration, self).__init__(test,
- params,
- env)
+ utils_test.MultihostMigration.__init__(self, test, params,
+ env)
def migration_scenario(self):
srchost = self.params.get("hosts")[0]
Please sign in to comment.
Something went wrong with that request. Please try again.