Changeset 79087 in vbox for trunk/src/VBox/ValidationKit
- Timestamp:
- Jun 11, 2019 11:58:28 AM (6 years ago)
- Location:
- trunk/src/VBox/ValidationKit
- Files:
-
- 79 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/ValidationKit/analysis/reader.py
r76553 r79087 37 37 import traceback 38 38 39 # pylint: disable= C011139 # pylint: disable=missing-docstring 40 40 41 41 class Value(object): -
trunk/src/VBox/ValidationKit/common/netutils.py
r76553 r79087 1 1 # -*- coding: utf-8 -*- 2 2 # $Id$ 3 # pylint: disable= C03023 # pylint: disable=too-many-lines 4 4 5 5 """ -
trunk/src/VBox/ValidationKit/common/utils.py
r78472 r79087 1 1 # -*- coding: utf-8 -*- 2 2 # $Id$ 3 # pylint: disable= C03023 # pylint: disable=too-many-lines 4 4 5 5 """ … … 320 320 else: 321 321 try: 322 from fcntl import FD_CLOEXEC, F_GETFD, F_SETFD, fcntl; # pylint: disable= F0401322 from fcntl import FD_CLOEXEC, F_GETFD, F_SETFD, fcntl; # pylint: disable=import-error 323 323 except: 324 324 # On windows, we can use the 'N' flag introduced in Visual C++ 7.0 or 7.1 with python 2.x. … … 399 399 if uPythonVer < ((3 << 16) | 4): 400 400 try: 401 from fcntl import FD_CLOEXEC, F_GETFD, F_SETFD, fcntl; # pylint: disable= F0401401 from fcntl import FD_CLOEXEC, F_GETFD, F_SETFD, fcntl; # pylint: disable=import-error 402 402 except: 403 403 pass; … … 411 411 """ 412 412 try: 413 sRet = os.readlink(sPath); # pylint: disable= E1101413 sRet = os.readlink(sPath); # pylint: disable=no-member 414 414 except: 415 415 return sXcptRet; … … 583 583 cbFreeSpace = oCTypeFreeSpace.value; 584 584 else: 585 oStats = os.statvfs(sPath); # pylint: disable= E1101585 oStats = os.statvfs(sPath); # pylint: disable=no-member 586 586 cbFreeSpace = long(oStats.f_frsize) * oStats.f_bfree; 587 587 … … 685 685 fIsRoot = True; 686 686 try: 687 fIsRoot = os.getuid() == 0; # pylint: disable= E1101687 fIsRoot = os.getuid() == 0; # pylint: disable=no-member 688 688 except: 689 689 pass; … … 797 797 else: 798 798 try: 799 os.kill(uPid, signal.SIGUSR1); # pylint: disable= E1101799 os.kill(uPid, signal.SIGUSR1); # pylint: disable=no-member 800 800 fRc = True; 801 801 except: … … 840 840 else: 841 841 try: 842 os.kill(uPid, signal.SIGKILL); # pylint: disable= E1101842 os.kill(uPid, signal.SIGKILL); # pylint: disable=no-member 843 843 fRc = True; 844 844 except: … … 898 898 if sys.platform == 'win32': 899 899 try: 900 from win32com.client import GetObject; # pylint: disable= F0401900 from win32com.client import GetObject; # pylint: disable=import-error 901 901 oWmi = GetObject('winmgmts:'); 902 902 aoProcesses = oWmi.InstancesOf('Win32_Process'); … … 1092 1092 1093 1093 1094 def processListAll(): # pylint: disable=R09141094 def processListAll(): 1095 1095 """ 1096 1096 Return a list of ProcessInfo objects for all the processes in the system … … 1101 1101 sOs = getHostOs(); 1102 1102 if sOs == 'win': 1103 from win32com.client import GetObject; # pylint: disable= F04011103 from win32com.client import GetObject; # pylint: disable=import-error 1104 1104 oWmi = GetObject('winmgmts:'); 1105 1105 aoProcesses = oWmi.InstancesOf('Win32_Process'); … … 2138 2138 # 2139 2139 2140 # pylint: disable= C01112140 # pylint: disable=missing-docstring 2141 2141 # pylint: disable=undefined-variable 2142 2142 class BuildCategoryDataTestCase(unittest.TestCase): -
trunk/src/VBox/ValidationKit/common/webutils.py
r76553 r79087 190 190 # 191 191 192 # pylint: disable= C0111192 # pylint: disable=missing-docstring 193 193 class CommonUtilsTestCase(unittest.TestCase): 194 194 def testHasSchema(self): -
trunk/src/VBox/ValidationKit/testboxscript/testboxconnection.py
r76553 r79087 149 149 # When connecting we're using a 15 second timeout, we increase it later. 150 150 # 151 if self._oParsedUrl.scheme == 'https': # pylint: disable= E1101151 if self._oParsedUrl.scheme == 'https': # pylint: disable=no-member 152 152 fnCtor = httplib.HTTPSConnection; 153 153 else: … … 199 199 'Connection': 'keep-alive', 200 200 }; 201 sServerPath = '/%s/testboxdisp.py' % (self._oParsedUrl.path.strip('/'),); # pylint: disable= E1101201 sServerPath = '/%s/testboxdisp.py' % (self._oParsedUrl.path.strip('/'),); # pylint: disable=no-member 202 202 dParams[constants.tbreq.ALL_PARAM_ACTION] = sAction; 203 203 sBody = urllib_urlencode(dParams); -
trunk/src/VBox/ValidationKit/testboxscript/testboxscript.py
r76553 r79087 51 51 52 52 53 class TestBoxScriptWrapper(object): # pylint: disable= R090353 class TestBoxScriptWrapper(object): # pylint: disable=too-few-public-methods 54 54 """ 55 55 Wrapper class -
trunk/src/VBox/ValidationKit/testboxscript/testboxscript_real.py
r76553 r79087 96 96 # Keys for config params 97 97 VALUE = 'value' 98 FN = 'fn' # pylint: disable= C010398 FN = 'fn' # pylint: disable=invalid-name 99 99 100 100 ## @} … … 136 136 sSubDir = 'testbox'; 137 137 try: 138 sSubDir = '%s-%u' % (sSubDir, os.getuid()); # pylint: disable= E1101138 sSubDir = '%s-%u' % (sSubDir, os.getuid()); # pylint: disable=no-member 139 139 except: 140 140 pass; … … 279 279 utils.sudoProcessCall(['/sbin/umount', sMountPoint]); 280 280 utils.sudoProcessCall(['/bin/mkdir', '-p', sMountPoint]); 281 utils.sudoProcessCall(['/usr/sbin/chown', str(os.getuid()), sMountPoint]); # pylint: disable= E1101281 utils.sudoProcessCall(['/usr/sbin/chown', str(os.getuid()), sMountPoint]); # pylint: disable=no-member 282 282 if sType == 'cifs': 283 283 # Note! no smb://server/share stuff here, 10.6.8 didn't like it. … … 302 302 + ',password=' + sPassword 303 303 + ',sec=ntlmv2' 304 + ',uid=' + str(os.getuid()) # pylint: disable= E1101305 + ',gid=' + str(os.getgid()) # pylint: disable= E1101304 + ',uid=' + str(os.getuid()) # pylint: disable=no-member 305 + ',gid=' + str(os.getgid()) # pylint: disable=no-member 306 306 + ',nounix,file_mode=0555,dir_mode=0555,soft,ro' 307 307 + sMountOpt, … … 330 330 '-o', 331 331 'user=' + sUser 332 + ',uid=' + str(os.getuid()) # pylint: disable= E1101333 + ',gid=' + str(os.getgid()) # pylint: disable= E1101332 + ',uid=' + str(os.getuid()) # pylint: disable=no-member 333 + ',gid=' + str(os.getgid()) # pylint: disable=no-member 334 334 + ',fileperms=0555,dirperms=0555,noxattr,ro' 335 335 + sMountOpt, … … 449 449 # Windows: WMI 450 450 try: 451 import win32com.client; # pylint: disable= F0401451 import win32com.client; # pylint: disable=import-error 452 452 oWmi = win32com.client.Dispatch('WbemScripting.SWbemLocator'); 453 453 oWebm = oWmi.ConnectServer('.', 'root\\cimv2'); … … 592 592 cMbFreeSpace = cTypeMbFreeSpace.value 593 593 else: 594 stats = os.statvfs(self._oOptions.sScratchRoot); # pylint: disable= E1101594 stats = os.statvfs(self._oOptions.sScratchRoot); # pylint: disable=no-member 595 595 cMbFreeSpace = stats.f_frsize * stats.f_bfree 596 596 … … 687 687 fUseTheForce = self._fFirstSignOn; 688 688 689 class ErrorCallback(object): # pylint: disable= R0903689 class ErrorCallback(object): # pylint: disable=too-few-public-methods 690 690 """ 691 691 Callbacks + state for the cleanup. -
trunk/src/VBox/ValidationKit/testboxscript/testboxtasks.py
r77165 r79087 432 432 close_fds = (False if utils.getHostOs() == 'win' else True), 433 433 preexec_fn = (None if utils.getHostOs() in ['win', 'os2'] 434 else os.setsid)); # pylint: disable= E1101434 else os.setsid)); # pylint: disable=no-member 435 435 except Exception as oXcpt: 436 436 self._log('Error creating child process %s: %s' % (asArgs, oXcpt)); … … 518 518 if iProcGroup > 0: 519 519 try: 520 os.killpg(iProcGroup, signal.SIGTERM); # pylint: disable= E1101520 os.killpg(iProcGroup, signal.SIGTERM); # pylint: disable=no-member 521 521 except Exception as oXcpt: 522 522 self._log('killpg() failed: %s' % (oXcpt,)); … … 534 534 if iProcGroup > 0: 535 535 try: 536 os.killpg(iProcGroup, signal.SIGKILL); # pylint: disable= E1101536 os.killpg(iProcGroup, signal.SIGKILL); # pylint: disable=no-member 537 537 except Exception as oXcpt: 538 538 self._log('killpg() failed: %s' % (oXcpt,)); -
trunk/src/VBox/ValidationKit/testdriver/base.py
r79067 r79087 1 1 # -*- coding: utf-8 -*- 2 2 # $Id$ 3 # pylint: disable= C03023 # pylint: disable=too-many-lines 4 4 5 5 """ … … 222 222 fRc = False; 223 223 else: 224 fRc = __processSudoKill(uPid, signal.SIGUSR1, fSudo); # pylint: disable= E1101224 fRc = __processSudoKill(uPid, signal.SIGUSR1, fSudo); # pylint: disable=no-member 225 225 return fRc; 226 226 … … 246 246 fRc = winbase.processKill(uPid); 247 247 else: 248 fRc = __processSudoKill(uPid, signal.SIGKILL, fSudo); # pylint: disable= E1101248 fRc = __processSudoKill(uPid, signal.SIGKILL, fSudo); # pylint: disable=no-member 249 249 return fRc; 250 250 … … 307 307 308 308 # ps fails with non-zero exit code if the pid wasn't found. 309 if iExitCode is not0:309 if iExitCode != 0: 310 310 return False; 311 311 if sCurName is None: … … 380 380 def __del__(self): 381 381 """In case we need it later on.""" 382 pass; 382 pass; # pylint: disable=unnecessary-pass 383 383 384 384 def toString(self): … … 395 395 def lockTask(self): 396 396 """ Wrapper around oCv.acquire(). """ 397 if True is True: # change to False for debugging deadlocks. 397 if True is True: # change to False for debugging deadlocks. # pylint: disable=comparison-with-itself 398 398 self.oCv.acquire(); 399 399 else: … … 600 600 try: 601 601 (uPid, uStatus) = os.waitpid(self.hWin, 0); 602 if uPid == self.hWin or uPid == self.uPid:602 if uPid in (self.hWin, self.uPid,): 603 603 self.hWin.Detach(); # waitpid closed it, so it's now invalid. 604 604 self.hWin = None; … … 613 613 else: 614 614 try: 615 (uPid, uStatus) = os.waitpid(self.uPid, os.WNOHANG); # pylint: disable= E1101615 (uPid, uStatus) = os.waitpid(self.uPid, os.WNOHANG); # pylint: disable=no-member 616 616 except: 617 617 reporter.logXcpt(); … … 773 773 774 774 775 class TestDriverBase(object): # pylint: disable= R0902775 class TestDriverBase(object): # pylint: disable=too-many-instance-attributes 776 776 """ 777 777 The base test driver. … … 1628 1628 1629 1629 1630 def innerMain(self, asArgs = None): # pylint: disable= R09151630 def innerMain(self, asArgs = None): # pylint: disable=too-many-statements 1631 1631 """ 1632 1632 Exception wrapped main() worker. … … 1749 1749 1750 1750 # The old, deprecated name. 1751 TestDriver = TestDriverBase; # pylint: disable= C01031751 TestDriver = TestDriverBase; # pylint: disable=invalid-name 1752 1752 1753 1753 … … 1756 1756 # 1757 1757 1758 # pylint: disable= C01111758 # pylint: disable=missing-docstring 1759 1759 class TestDriverBaseTestCase(unittest.TestCase): 1760 1760 def setUp(self): -
trunk/src/VBox/ValidationKit/testdriver/btresolver.py
r76553 r79087 1 1 # -*- coding: utf-8 -*- 2 2 # $Id$ 3 # pylint: disable= C03023 # pylint: disable=too-many-lines 4 4 5 5 """ … … 548 548 self.oResolverOs = BacktraceResolverOsLinux(self.sScratchDbgPath, self.sScratchPath, self.fnLog); 549 549 elif self.sTargetOs == 'darwin': 550 self.oResolverOs = BacktraceResolverOsDarwin(self.sScratchDbgPath, self.sScratchPath, self.fnLog); # pylint: disable= R0204550 self.oResolverOs = BacktraceResolverOsDarwin(self.sScratchDbgPath, self.sScratchPath, self.fnLog); # pylint: disable=redefined-variable-type 551 551 elif self.sTargetOs == 'solaris': 552 self.oResolverOs = BacktraceResolverOsSolaris(self.sScratchDbgPath, self.sScratchPath, self.fnLog); # pylint: disable= R0204552 self.oResolverOs = BacktraceResolverOsSolaris(self.sScratchDbgPath, self.sScratchPath, self.fnLog); # pylint: disable=redefined-variable-type 553 553 else: 554 554 self.log('The backtrace resolver is not supported on %s' % (self.sTargetOs,)); -
trunk/src/VBox/ValidationKit/testdriver/reporter.py
r78973 r79087 1 1 # -*- coding: utf-8 -*- 2 2 # $Id$ 3 # pylint: disable= C03023 # pylint: disable=too-many-lines 4 4 5 5 """ … … 677 677 if sys.version_info[0] >= 3 \ 678 678 or (sys.version_info[0] == 2 and sys.version_info[1] >= 6): 679 if self._oParsedTmUrl.scheme == 'https': # pylint: disable= E1101679 if self._oParsedTmUrl.scheme == 'https': # pylint: disable=no-member 680 680 self._fnTmConnect = lambda: httplib.HTTPSConnection(self._oParsedTmUrl.hostname, 681 681 timeout = self.kcSecTestManagerRequestTimeout); … … 684 684 timeout = self.kcSecTestManagerRequestTimeout); 685 685 else: 686 if self._oParsedTmUrl.scheme == 'https': # pylint: disable= E1101686 if self._oParsedTmUrl.scheme == 'https': # pylint: disable=no-member 687 687 self._fnTmConnect = lambda: httplib.HTTPSConnection(self._oParsedTmUrl.hostname); 688 688 else: … … 704 704 }; 705 705 self._sTmServerPath = '/%s/testboxdisp.py?%s' \ 706 % ( self._oParsedTmUrl.path.strip('/'), # pylint: disable= E1101706 % ( self._oParsedTmUrl.path.strip('/'), # pylint: disable=no-member 707 707 self._fnUrlEncode(dParams), ); 708 708 … … 1687 1687 1688 1688 cThread = 0; 1689 for idThread, oStack in sys._current_frames().items(): # >=2.5, a bit ugly - pylint: disable= W02121689 for idThread, oStack in sys._current_frames().items(): # >=2.5, a bit ugly - pylint: disable=protected-access 1690 1690 try: 1691 1691 if cThread > 0: -
trunk/src/VBox/ValidationKit/testdriver/tst-txsclient.py
r76553 r79087 69 69 return 'FAILED'; 70 70 71 def main(asArgs): # pylint: disable= C0111,R0914,R091571 def main(asArgs): # pylint: disable=missing-docstring,too-many-locals,too-many-statements 72 72 cMsTimeout = long(30*1000); 73 73 sAddress = 'localhost'; -
trunk/src/VBox/ValidationKit/testdriver/txsclient.py
r76553 r79087 1 1 # -*- coding: utf-8 -*- 2 2 # $Id$ 3 # pylint: disable= C03023 # pylint: disable=too-many-lines 4 4 5 5 """ … … 719 719 # 720 720 # Process task 721 # pylint: disable= C0111721 # pylint: disable=missing-docstring 722 722 # 723 723 724 def taskExecEx(self, sExecName, fFlags, asArgs, asAddEnv, oStdIn, oStdOut, oStdErr, oTestPipe, sAsUser): # pylint: disable= R0913,R0914,R0915,C0301724 def taskExecEx(self, sExecName, fFlags, asArgs, asAddEnv, oStdIn, oStdOut, oStdErr, oTestPipe, sAsUser): # pylint: disable=too-many-arguments,too-many-locals,too-many-statements,line-too-long 725 725 # Construct the payload. 726 726 aoPayload = [long(fFlags), '%s' % (sExecName), long(len(asArgs))]; … … 918 918 for o in (oStdIn, oStdOut, oStdErr, oTestPipe): 919 919 if o is not None and not utils.isString(o): 920 del o.uTxsClientCrc32; # pylint: disable= E1103920 del o.uTxsClientCrc32; # pylint: disable=maybe-no-member 921 921 # Make sure all files are closed 922 o.close(); # pylint: disable= E1103922 o.close(); # pylint: disable=maybe-no-member 923 923 reporter.log('taskExecEx: returns %s' % (rc)); 924 924 return rc; … … 1051 1051 def taskUploadString(self, sContent, sRemoteFile): 1052 1052 # Wrap sContent in a file like class. 1053 class InStringFile(object): # pylint: disable= R09031053 class InStringFile(object): # pylint: disable=too-few-public-methods 1054 1054 def __init__(self, sContent): 1055 1055 self.sContent = sContent; … … 1148 1148 def taskDownloadString(self, sRemoteFile, sEncoding = 'utf-8', fIgnoreEncodingErrors = True): 1149 1149 # Wrap sContent in a file like class. 1150 class OutStringFile(object): # pylint: disable= R09031150 class OutStringFile(object): # pylint: disable=too-few-public-methods 1151 1151 def __init__(self): 1152 1152 self.asContent = []; … … 1232 1232 return rc; 1233 1233 1234 # pylint: enable= C01111234 # pylint: enable=missing-docstring 1235 1235 1236 1236 … … 1310 1310 # 1311 1311 1312 def asyncExecEx(self, sExecName, asArgs = (), asAddEnv = (), # pylint: disable= R09131312 def asyncExecEx(self, sExecName, asArgs = (), asAddEnv = (), # pylint: disable=too-many-arguments 1313 1313 oStdIn = None, oStdOut = None, oStdErr = None, oTestPipe = None, 1314 1314 sAsUser = "", cMsTimeout = 3600000, fIgnoreErrors = False): … … 1339 1339 oStdOut, oStdErr, oTestPipe, sAsUser)); 1340 1340 1341 def syncExecEx(self, sExecName, asArgs = (), asAddEnv = (), # pylint: disable= R09131341 def syncExecEx(self, sExecName, asArgs = (), asAddEnv = (), # pylint: disable=too-many-arguments 1342 1342 oStdIn = '/dev/null', oStdOut = '/dev/null', 1343 1343 oStdErr = '/dev/null', oTestPipe = '/dev/null', … … 1895 1895 oWakeupW = None; 1896 1896 if hasattr(socket, 'socketpair'): 1897 try: (oWakeupR, oWakeupW) = socket.socketpair(); # pylint: disable= E11011897 try: (oWakeupR, oWakeupW) = socket.socketpair(); # pylint: disable=no-member 1898 1898 except: reporter.logXcpt('socket.socketpair() failed'); 1899 1899 -
trunk/src/VBox/ValidationKit/testdriver/vbox.py
r79056 r79087 1 1 # -*- coding: utf-8 -*- 2 2 # $Id$ 3 # pylint: disable= C03023 # pylint: disable=too-many-lines 4 4 5 5 """ … … 68 68 # 69 69 70 ComException = None; # pylint: disable= C010371 __fnComExceptionGetAttr__ = None; # pylint: disable= C010370 ComException = None; # pylint: disable=invalid-name 71 __fnComExceptionGetAttr__ = None; # pylint: disable=invalid-name 72 72 73 73 def __MyDefaultGetAttr(oSelf, sName): … … 110 110 exceptions and errors. 111 111 """ 112 global ComException # pylint: disable= C0103113 global __fnComExceptionGetAttr__ # pylint: disable= C0103112 global ComException # pylint: disable=invalid-name 113 global __fnComExceptionGetAttr__ # pylint: disable=invalid-name 114 114 115 115 # Hook up our attribute getter for the exception class (ASSUMES new-style). … … 210 210 211 211 # Reverse lookup table. 212 dDecimalToConst = {}; # pylint: disable= C0103212 dDecimalToConst = {}; # pylint: disable=invalid-name 213 213 214 214 def __init__(self): … … 329 329 330 330 331 class Build(object): # pylint: disable= R0903331 class Build(object): # pylint: disable=too-few-public-methods 332 332 """ 333 333 A VirtualBox build. … … 372 372 sSearch = os.environ.get('VBOX_TD_DEV_TREE', os.path.dirname(__file__)); # Env.var. for older trees or testboxscript. 373 373 sCandidat = None; 374 for i in range(0, 10): # pylint: disable= W0612374 for i in range(0, 10): # pylint: disable=unused-variable 375 375 sBldDir = os.path.join(sSearch, sOut); 376 376 if os.path.isdir(sBldDir): … … 453 453 self.oEventSrc = dArgs['oEventSrc']; # Console/VirtualBox for < 3.3 454 454 self.oListener = dArgs['oListener']; 455 self.fPassive = self.oListener !=None;455 self.fPassive = self.oListener is not None; 456 456 self.sName = sName 457 457 self.fShutdown = False; … … 616 616 617 617 618 # pylint: disable= C0111,R0913,W0613618 # pylint: disable=missing-docstring,too-many-arguments,unused-argument 619 619 def onMousePointerShapeChange(self, fVisible, fAlpha, xHot, yHot, cx, cy, abShape): 620 620 reporter.log2('onMousePointerShapeChange/%s' % (self.sName)); … … 657 657 reporter.log2('onShowWindow/%s' % (self.sName)); 658 658 return None; 659 # pylint: enable= C0111,R0913,W0613659 # pylint: enable=missing-docstring,too-many-arguments,unused-argument 660 660 661 661 def handleEvent(self, oEvt): … … 698 698 EventHandlerBase.__init__(self, dArgs, self.oVBox.fpApiVer, sName); 699 699 700 # pylint: disable= C0111,W0613700 # pylint: disable=missing-docstring,unused-argument 701 701 def onMachineStateChange(self, sMachineId, eState): 702 702 pass; … … 724 724 def onGuestPropertyChange(self, sMachineId, sName, sValue, sFlags): 725 725 pass; 726 # pylint: enable= C0111,W0613726 # pylint: enable=missing-docstring,unused-argument 727 727 728 728 def handleEvent(self, oEvt): … … 763 763 ConsoleEventHandlerBase.__init__(self, dArgs); 764 764 765 def onMachineStateChange(self, sMachineId, eState): # pylint: disable= W0613765 def onMachineStateChange(self, sMachineId, eState): # pylint: disable=unused-argument 766 766 """ Just interrupt the wait loop here so it can check again. """ 767 767 _ = sMachineId; _ = eState; … … 782 782 783 783 784 class TestDriver(base.TestDriver): # pylint: disable= R0902784 class TestDriver(base.TestDriver): # pylint: disable=too-many-instance-attributes 785 785 """ 786 786 This is the VirtualBox test driver. … … 846 846 847 847 # Try dev build first since that's where I'll be using it first... 848 if True is True: 848 if True is True: # pylint: disable=comparison-with-itself 849 849 try: 850 850 self.oBuild = Build(self, None); … … 1008 1008 return self.fImportedVBoxApi; 1009 1009 1010 def _startVBoxSVC(self): # pylint: disable= R09151010 def _startVBoxSVC(self): # pylint: disable=too-many-statements 1011 1011 """ Starts VBoxSVC. """ 1012 1012 assert(self.oVBoxSvcProcess is None); … … 1058 1058 sWinDbg = 'c:\\Program Files\\Debugging Tools for Windows\\windbg.exe'; 1059 1059 if not os.path.isfile(sWinDbg): sWinDbg = 'c:\\Program Files\\Debugging Tools for Windows (x64)\\windbg.exe'; 1060 if not os.path.isfile(sWinDbg): sWinDbg = 'c:\\Programme\\Debugging Tools for Windows\\windbg.exe'; # Localization rulez! pylint: disable= C03011060 if not os.path.isfile(sWinDbg): sWinDbg = 'c:\\Programme\\Debugging Tools for Windows\\windbg.exe'; # Localization rulez! pylint: disable=line-too-long 1061 1061 if not os.path.isfile(sWinDbg): sWinDbg = 'c:\\Programme\\Debugging Tools for Windows (x64)\\windbg.exe'; 1062 1062 if not os.path.isfile(sWinDbg): sWinDbg = 'windbg'; # WinDbg must be in the path; better than nothing. … … 1087 1087 self.oVBoxSvcProcess = base.Process.spawn(sVBoxSVC, sVBoxSVC, '--auto-shutdown'); # SIGUSR1 requirement. 1088 1088 try: # Try make sure we get the SIGINT and not VBoxSVC. 1089 os.setpgid(self.oVBoxSvcProcess.getPid(), 0); # pylint: disable= E11011090 os.setpgid(0, 0); # pylint: disable= E11011089 os.setpgid(self.oVBoxSvcProcess.getPid(), 0); # pylint: disable=no-member 1090 os.setpgid(0, 0); # pylint: disable=no-member 1091 1091 except: 1092 1092 reporter.logXcpt(); … … 1129 1129 # Fudge and pid file. 1130 1130 # 1131 if self.oVBoxSvcProcess !=None and not self.oVBoxSvcProcess.wait(cMsFudge):1131 if self.oVBoxSvcProcess is not None and not self.oVBoxSvcProcess.wait(cMsFudge): 1132 1132 if fWritePidFile: 1133 1133 iPid = self.oVBoxSvcProcess.getPid(); … … 1149 1149 except: pass; 1150 1150 1151 return self.oVBoxSvcProcess !=None;1151 return self.oVBoxSvcProcess is not None; 1152 1152 1153 1153 … … 1261 1261 1262 1262 try: 1263 from vboxapi import VirtualBoxManager # pylint: disable=import-error1263 from vboxapi import VirtualBoxManager; # pylint: disable=import-error 1264 1264 except: 1265 1265 reporter.logXcpt('Error importing vboxapi'); … … 1270 1270 # pylint: disable=import-error 1271 1271 if self.sHost == 'win': 1272 from pythoncom import com_error as NativeComExceptionClass # pylint: disable= E06111272 from pythoncom import com_error as NativeComExceptionClass # pylint: disable=no-name-in-module 1273 1273 import winerror as NativeComErrorClass 1274 1274 else: … … 1392 1392 if oXcpt is None: oXcpt = sys.exc_info()[1]; 1393 1393 if sys.platform == 'win32': 1394 from pythoncom import com_error as NativeComExceptionClass # pylint: disable=import-error, E06111394 from pythoncom import com_error as NativeComExceptionClass # pylint: disable=import-error,no-name-in-module 1395 1395 else: 1396 1396 from xpcom import Exception as NativeComExceptionClass # pylint: disable=import-error … … 1400 1400 """ See vboxapi. """ 1401 1401 hrXcpt = oSelf.xcptGetResult(oXcpt); 1402 return hrXcpt == hrStatus or hrXcpt == hrStatus - 0x100000000; 1402 return hrXcpt == hrStatus or hrXcpt == hrStatus - 0x100000000; # pylint: disable=consider-using-in 1403 1403 1404 1404 def _xcptToString(oSelf, oXcpt): … … 1478 1478 # Also, it keeps a number of internal objects and interfaces around to do its job, so shutting 1479 1479 # it down before we go looking for dangling interfaces is more or less required. 1480 from xpcom import _xpcom as _xpcom; # pylint: disable=import-error 1480 from xpcom import _xpcom as _xpcom; # pylint: disable=import-error,useless-import-alias 1481 1481 hrc = _xpcom.DeinitCOM(); 1482 cIfs = _xpcom._GetInterfaceCount(); # pylint: disable= W02121483 cObjs = _xpcom._GetGatewayCount(); # pylint: disable= W02121482 cIfs = _xpcom._GetInterfaceCount(); # pylint: disable=protected-access 1483 cObjs = _xpcom._GetGatewayCount(); # pylint: disable=protected-access 1484 1484 1485 1485 if cObjs == 0 and cIfs == 0: … … 1489 1489 % (cObjs, cIfs, hrc)); 1490 1490 if hasattr(_xpcom, '_DumpInterfaces'): 1491 try: _xpcom._DumpInterfaces(); # pylint: disable= W02121491 try: _xpcom._DumpInterfaces(); # pylint: disable=protected-access 1492 1492 except: reporter.logXcpt('_teardownVBoxApi: _DumpInterfaces failed'); 1493 1493 … … 1666 1666 return rc; 1667 1667 1668 def parseOption(self, asArgs, iArg): # pylint: disable= R09151668 def parseOption(self, asArgs, iArg): # pylint: disable=too-many-statements 1669 1669 if asArgs[iArg] == '--vbox-session-type': 1670 1670 iArg += 1; … … 1945 1945 return None; 1946 1946 1947 def _logVmInfoUnsafe(self, oVM): # pylint: disable= R0915,R09121947 def _logVmInfoUnsafe(self, oVM): # pylint: disable=too-many-statements,too-many-branches 1948 1948 """ 1949 1949 Internal worker for logVmInfo that is wrapped in try/except. … … 2153 2153 return True; 2154 2154 2155 def logVmInfo(self, oVM): # pylint: disable= R0915,R09122155 def logVmInfo(self, oVM): # pylint: disable=too-many-statements,too-many-branches 2156 2156 """ 2157 2157 Logs VM configuration details. … … 2194 2194 reporter.logXcpt(); 2195 2195 else: 2196 if sIdOrDesc == sId or sIdOrDesc == sDesc:2196 if sIdOrDesc in (sId, sDesc,): 2197 2197 sIdOrDesc = sId; 2198 2198 break; … … 2239 2239 return oVM; 2240 2240 except: 2241 reporter.logXcpt(); 2241 2242 raise; 2242 2243 except: … … 2259 2260 return None; 2260 2261 2261 # pylint: disable= R0913,R0914,R09152262 # pylint: disable=too-many-arguments,too-many-locals,too-many-statements 2262 2263 def createTestVM(self, 2263 2264 sName, … … 2375 2376 self.logVmInfo(oVM); # testing... 2376 2377 return oVM; 2377 # pylint: enable= R0913,R0914,R09152378 # pylint: enable=too-many-arguments,too-many-locals,too-many-statements 2378 2379 2379 2380 def createTestVmWithDefaults(self, # pylint: disable=too-many-arguments … … 2609 2610 and sCurName != '' \ 2610 2611 and base.timestampMilli() - msStart < cMsTimeout \ 2611 and ( eCurState == vboxcon.SessionState_Unlocking \ 2612 or eCurState == vboxcon.SessionState_Spawning \ 2613 or eCurState == vboxcon.SessionState_Locked): 2612 and eCurState in (vboxcon.SessionState_Unlocking, vboxcon.SessionState_Spawning, vboxcon.SessionState_Locked,): 2614 2613 self.processEvents(1000); 2615 2614 try: … … 2662 2661 return fRc; 2663 2662 2664 def startVmEx(self, oVM, fWait = True, sType = None, sName = None, asEnv = None): # pylint: disable= R0914,R09152663 def startVmEx(self, oVM, fWait = True, sType = None, sName = None, asEnv = None): # pylint: disable=too-many-locals,too-many-statements 2665 2664 """ 2666 2665 Start the VM, returning the VM session and progress object on success. … … 2758 2757 if self.fpApiVer < 4.3 \ 2759 2758 or (self.fpApiVer == 4.3 and not hasattr(self.oVBoxMgr, 'getSessionObject')): 2760 oSession = self.oVBoxMgr.mgr.getSessionObject(self.oVBox); # pylint: disable= E11012759 oSession = self.oVBoxMgr.mgr.getSessionObject(self.oVBox); # pylint: disable=no-member 2761 2760 elif self.fpApiVer < 5.2 \ 2762 2761 or (self.fpApiVer == 5.2 and hasattr(self.oVBoxMgr, 'vbox')): 2763 oSession = self.oVBoxMgr.getSessionObject(self.oVBox); # pylint: disable= E11012762 oSession = self.oVBoxMgr.getSessionObject(self.oVBox); # pylint: disable=no-member 2764 2763 else: 2765 oSession = self.oVBoxMgr.getSessionObject(); # pylint: disable=E1101,E11202764 oSession = self.oVBoxMgr.getSessionObject(); # pylint: disable=no-member,no-value-for-parameter 2766 2765 if self.fpApiVer < 3.3: 2767 2766 oProgress = self.oVBox.openRemoteSession(oSession, sUuid, sType, sEnv); … … 2775 2774 oSession = None; 2776 2775 if i >= 0: 2777 reporter.logXcpt('warning: failed to start VM "%s" ("%s") - retrying in %u secs.' % (sUuid, oVM, i)); # pylint: disable= C03012776 reporter.logXcpt('warning: failed to start VM "%s" ("%s") - retrying in %u secs.' % (sUuid, oVM, i)); # pylint: disable=line-too-long 2778 2777 self.waitOnDirectSessionClose(oVM, 5000 + i * 1000); 2779 2778 if fWait and oProgress is not None: … … 2842 2841 return oSession; 2843 2842 2844 def terminateVmBySession(self, oSession, oProgress = None, fTakeScreenshot = None): # pylint: disable= R09152843 def terminateVmBySession(self, oSession, oProgress = None, fTakeScreenshot = None): # pylint: disable=too-many-statements 2845 2844 """ 2846 2845 Terminates the VM specified by oSession and adds the release logs to … … 3291 3290 fRemoveTxs = self.addTask(oTxsSession); 3292 3291 3293 rc = fnAsync(*aArgs); # pylint: disable= W01423292 rc = fnAsync(*aArgs); # pylint: disable=star-args 3294 3293 if rc is True: 3295 3294 rc = False; … … 3325 3324 return rc; 3326 3325 3327 # pylint: disable= C01113326 # pylint: disable=missing-docstring 3328 3327 3329 3328 def txsDisconnect(self, oSession, oTxsSession, cMsTimeout = 30000, fIgnoreErrors = False): … … 3424 3423 (sRemoteFile, sRemoteDir, self.adjustTimeoutMs(cMsTimeout), fIgnoreErrors)); 3425 3424 3426 # pylint: enable= C01113425 # pylint: enable=missing-docstring 3427 3426 3428 3427 def txsCdWait(self, … … 3652 3651 return (fRc, oTxsSession); 3653 3652 3654 # pylint: disable= R0914,R09133653 # pylint: disable=too-many-locals,too-many-arguments 3655 3654 3656 3655 def txsRunTest(self, oTxsSession, sTestName, cMsTimeout, sExecName, asArgs = (), asAddEnv = (), sAsUser = ""): … … 3810 3809 return fRc; 3811 3810 3812 # pylint: enable= R0914,R09133811 # pylint: enable=too-many-locals,too-many-arguments 3813 3812 3814 3813 -
trunk/src/VBox/ValidationKit/testdriver/vboxcon.py
r76553 r79087 36 36 37 37 38 class VBoxConstantWrappingHack(object): # pylint: disable= R090338 class VBoxConstantWrappingHack(object): # pylint: disable=too-few-public-methods 39 39 """ 40 40 This is a hack to avoid the self.oVBoxMgr.constants.MachineState_Running … … 80 80 81 81 82 goHackModuleClass = VBoxConstantWrappingHack(sys.modules[__name__]); # pylint: disable= C010382 goHackModuleClass = VBoxConstantWrappingHack(sys.modules[__name__]); # pylint: disable=invalid-name 83 83 sys.modules[__name__] = goHackModuleClass; 84 84 -
trunk/src/VBox/ValidationKit/testdriver/vboxinstaller.py
r78385 r79087 837 837 """ 838 838 839 import win32com.client; # pylint: disable= F0401839 import win32com.client; # pylint: disable=import-error 840 840 win32com.client.gencache.EnsureModule('{000C1092-0000-0000-C000-000000000046}', 1033, 1, 0); 841 841 oInstaller = win32com.client.Dispatch('WindowsInstaller.Installer', -
trunk/src/VBox/ValidationKit/testdriver/vboxtestvms.py
r79071 r79087 71 71 ## @name Flags. 72 72 ## @{ 73 g_k32 = 32; # pylint: disable= C010374 g_k64 = 64; # pylint: disable= C010375 g_k32_64 = 96; # pylint: disable= C010373 g_k32 = 32; # pylint: disable=invalid-name 74 g_k64 = 64; # pylint: disable=invalid-name 75 g_k32_64 = 96; # pylint: disable=invalid-name 76 76 g_kiArchMask = 96; 77 77 g_kiNoRaw = 128; ##< No raw mode. … … 87 87 88 88 # Table translating from VM name core to a more detailed guest info. 89 # pylint: disable= C030189 # pylint: disable=line-too-long 90 90 ## @todo what's the difference between the first two columns again? 91 91 g_aaNameToDetails = \ … … 179 179 180 180 181 # pylint: enable= C0301181 # pylint: enable=line-too-long 182 182 183 183 def _intersects(asSet1, asSet2): … … 199 199 """ 200 200 201 def __init__(self, # pylint: disable= R0913201 def __init__(self, # pylint: disable=too-many-arguments 202 202 sVmName, # type: str 203 203 fGrouping = 0, # type: int … … 904 904 """ 905 905 906 def __init__(self, # pylint: disable= R0913906 def __init__(self, # pylint: disable=too-many-arguments 907 907 sVmName, # type: str 908 908 fGrouping = 0, # type: int … … 1395 1395 1396 1396 1397 def __init__(self, # pylint: disable= R09131397 def __init__(self, # pylint: disable=too-many-arguments 1398 1398 sVmName, # type: str 1399 1399 fGrouping = g_kfGrpAncient | g_kfGrpNoTxs, # type: int … … 1703 1703 return True; 1704 1704 1705 def actionExecute(self, oTestDrv, fnCallback): # pylint: disable= R09141705 def actionExecute(self, oTestDrv, fnCallback): # pylint: disable=too-many-locals 1706 1706 """ 1707 1707 For base.TestDriver.actionExecute. Calls the callback function for -
trunk/src/VBox/ValidationKit/testdriver/vboxwrappers.py
r79068 r79087 1 1 # -*- coding: utf-8 -*- 2 2 # $Id$ 3 # pylint: disable= C03023 # pylint: disable=too-many-lines 4 4 5 5 """ … … 102 102 103 103 104 class VirtualBoxWrapper(object): # pylint: disable= R0903104 class VirtualBoxWrapper(object): # pylint: disable=too-few-public-methods 105 105 """ 106 106 Wrapper around the IVirtualBox object that adds some (hopefully) useful … … 509 509 they don't throw errors. 510 510 """ 511 if True is True: 511 if True is True: # pylint: disable=comparison-with-itself 512 512 try: 513 513 iPct = self.o.operationPercent; … … 1280 1280 Helper that translate the adapter type into a driver name. 1281 1281 """ 1282 if eNicType == vboxcon.NetworkAdapterType_Am79C970A \ 1283 or eNicType == vboxcon.NetworkAdapterType_Am79C973: 1282 if eNicType in (vboxcon.NetworkAdapterType_Am79C970A, vboxcon.NetworkAdapterType_Am79C973): 1284 1283 sName = 'pcnet'; 1285 elif eNicType == vboxcon.NetworkAdapterType_I82540EM \1286 or eNicType == vboxcon.NetworkAdapterType_I82543GC \1287 or eNicType == vboxcon.NetworkAdapterType_I82545EM:1284 elif eNicType in (vboxcon.NetworkAdapterType_I82540EM, 1285 vboxcon.NetworkAdapterType_I82543GC, 1286 vboxcon.NetworkAdapterType_I82545EM): 1288 1287 sName = 'e1000'; 1289 1288 elif eNicType == vboxcon.NetworkAdapterType_Virtio: … … 1562 1561 # Resolve missing MAC address prefix by feeding in the host IP address bytes. 1563 1562 cchMacAddr = len(sMacAddr); 1564 if cchMacAddr > 0 andcchMacAddr < 12:1563 if 0 < cchMacAddr < 12: 1565 1564 sHostIP = netutils.getPrimaryHostIp(); 1566 1565 abHostIP = socket.inet_aton(sHostIP); … … 1925 1924 return oHd; 1926 1925 1927 def createAndAttachHd(self, sHd, sFmt = "VDI", sController = "IDE Controller", cb = 10*1024*1024*1024, # pylint: disable= R09131926 def createAndAttachHd(self, sHd, sFmt = "VDI", sController = "IDE Controller", cb = 10*1024*1024*1024, # pylint: disable=too-many-arguments 1928 1927 iPort = 0, iDevice = 0, fImmutable = True, cMsTimeout = 60000, tMediumVariant = None): 1929 1928 """ … … 2115 2114 return True; 2116 2115 2117 def setupPreferredConfig(self): # pylint: disable= R09142116 def setupPreferredConfig(self): # pylint: disable=too-many-locals 2118 2117 """ 2119 2118 Configures the VM according to the preferences of the guest type. … … 2180 2179 if not self.enableUsbHid(fUsbHid): fRc = False; 2181 2180 if not self.enableHpet(fHpet): fRc = False; 2182 if eStorCtlType == vboxcon.StorageControllerType_PIIX3 \2183 or eStorCtlType == vboxcon.StorageControllerType_PIIX4 \2184 or eStorCtlType == vboxcon.StorageControllerType_ICH6:2181 if eStorCtlType in (vboxcon.StorageControllerType_PIIX3, 2182 vboxcon.StorageControllerType_PIIX4, 2183 vboxcon.StorageControllerType_ICH6,): 2185 2184 if not self.setStorageControllerType(eStorCtlType, "IDE Controller"): 2186 2185 fRc = False; … … 2190 2189 return fRc; 2191 2190 2192 def addUsbDeviceFilter(self, sName, sVendorId = None, sProductId = None, sRevision = None, # pylint: disable= R09132191 def addUsbDeviceFilter(self, sName, sVendorId = None, sProductId = None, sRevision = None, # pylint: disable=too-many-arguments 2193 2192 sManufacturer = None, sProduct = None, sSerialNumber = None, 2194 2193 sPort = None, sRemote = None): … … 3033 3032 """ Class for looking for IPv4 address changes on interface 0.""" 3034 3033 def __init__(self, dArgs): 3035 vbox.VirtualBoxEventHandlerBase.__init__(self, dArgs); # pylint: disable=W02333034 vbox.VirtualBoxEventHandlerBase.__init__(self, dArgs); 3036 3035 self.oParentTask = dArgs['oParentTask']; 3037 3036 self.sMachineId = dArgs['sMachineId']; … … 3044 3043 oParentTask = self.oParentTask; 3045 3044 if oParentTask: 3046 oParentTask._setIp(sValue); # pylint: disable= W02123045 oParentTask._setIp(sValue); # pylint: disable=protected-access 3047 3046 3048 3047 -
trunk/src/VBox/ValidationKit/testdriver/winbase.py
r76553 r79087 143 143 if fRc is True: 144 144 try: 145 from win32com.client import GetObject; # pylint: disable= F0401145 from win32com.client import GetObject; # pylint: disable=import-error 146 146 oWmi = GetObject('winmgmts:'); 147 147 aoProcesses = oWmi.InstancesOf('Win32_Process'); -
trunk/src/VBox/ValidationKit/testmanager/batch/add_build.py
r76553 r79087 2 2 # -*- coding: utf-8 -*- 3 3 # $Id$ 4 # pylint: disable= C03014 # pylint: disable=line-too-long 5 5 6 6 """ … … 44 44 from testmanager.core.build import BuildDataEx, BuildLogic, BuildCategoryData; 45 45 46 class Build(object): # pylint: disable= R090346 class Build(object): # pylint: disable=too-few-public-methods 47 47 """ 48 48 Add build info into Test Manager database. -
trunk/src/VBox/ValidationKit/testmanager/batch/check_for_deleted_builds.py
r76553 r79087 2 2 # -*- coding: utf-8 -*- 3 3 # $Id$ 4 # pylint: disable= C03014 # pylint: disable=line-too-long 5 5 6 6 """ … … 53 53 54 54 55 class BuildChecker(object): # pylint: disable= R090355 class BuildChecker(object): # pylint: disable=too-few-public-methods 56 56 """ 57 57 Add build info into Test Manager database. -
trunk/src/VBox/ValidationKit/testmanager/batch/close_orphaned_testsets.py
r76553 r79087 2 2 # -*- coding: utf-8 -*- 3 3 # $Id$ 4 # pylint: disable= C03014 # pylint: disable=line-too-long 5 5 6 6 """ -
trunk/src/VBox/ValidationKit/testmanager/batch/del_build.py
r76553 r79087 2 2 # -*- coding: utf-8 -*- 3 3 # $Id$ 4 # pylint: disable= C03014 # pylint: disable=line-too-long 5 5 6 6 """ -
trunk/src/VBox/ValidationKit/testmanager/batch/filearchiver.py
r76553 r79087 2 2 # -*- coding: utf-8 -*- 3 3 # $Id$ 4 # pylint: disable= C03014 # pylint: disable=line-too-long 5 5 6 6 """ … … 53 53 54 54 55 class FileArchiverBatchJob(object): # pylint: disable= R090355 class FileArchiverBatchJob(object): # pylint: disable=too-few-public-methods 56 56 """ 57 57 Log+files comp -
trunk/src/VBox/ValidationKit/testmanager/batch/regen_sched_queues.py
r76553 r79087 2 2 # -*- coding: utf-8 -*- 3 3 # $Id$ 4 # pylint: disable= C03014 # pylint: disable=line-too-long 5 5 6 6 """ … … 49 49 50 50 51 class RegenSchedQueues(object): # pylint: disable= R090351 class RegenSchedQueues(object): # pylint: disable=too-few-public-methods 52 52 """ 53 53 Regenerates all the scheduling queues. -
trunk/src/VBox/ValidationKit/testmanager/batch/vcs_import.py
r76553 r79087 2 2 # -*- coding: utf-8 -*- 3 3 # $Id$ 4 # pylint: disable= C03014 # pylint: disable=line-too-long 5 5 6 6 """ … … 48 48 from common import utils; 49 49 50 class VcsImport(object): # pylint: disable= R090350 class VcsImport(object): # pylint: disable=too-few-public-methods 51 51 """ 52 52 Imports revision history from a VSC into the Test Manager database. -
trunk/src/VBox/ValidationKit/testmanager/batch/virtual_test_sheriff.py
r78770 r79087 2 2 # -*- coding: utf-8 -*- 3 3 # $Id$ 4 # pylint: disable= C03014 # pylint: disable=line-too-long 5 5 6 6 """ … … 275 275 276 276 277 class VirtualTestSheriff(object): # pylint: disable= R0903277 class VirtualTestSheriff(object): # pylint: disable=too-few-public-methods 278 278 """ 279 279 Add build info into Test Manager database. -
trunk/src/VBox/ValidationKit/testmanager/core/base.py
r76553 r79087 1 1 # -*- coding: utf-8 -*- 2 2 # $Id$ 3 # pylint: disable= C03023 # pylint: disable=too-many-lines 4 4 5 5 """ … … 44 44 # Python 3 hacks: 45 45 if sys.version_info[0] >= 3: 46 long = int # pylint: disable= W0622,C010346 long = int # pylint: disable=redefined-builtin,invalid-name 47 47 48 48 … … 51 51 For exceptions raised by any TestManager component. 52 52 """ 53 pass; 53 pass; # pylint: disable=unnecessary-pass 54 54 55 55 … … 59 59 Used by ModelLogicBase decendants. 60 60 """ 61 pass; 61 pass; # pylint: disable=unnecessary-pass 62 62 63 63 … … 67 67 Used by ModelLogicBase decendants. 68 68 """ 69 pass; 69 pass; # pylint: disable=unnecessary-pass 70 70 71 71 … … 75 75 Used by ModelLogicBase decendants. 76 76 """ 77 pass; 77 pass; # pylint: disable=unnecessary-pass 78 78 79 79 … … 83 83 Used by ModelLogicBase decendants. 84 84 """ 85 pass; 85 pass; # pylint: disable=unnecessary-pass 86 86 87 87 … … 91 91 Used by ModelLogicBase decendants. 92 92 """ 93 pass; 93 pass; # pylint: disable=unnecessary-pass 94 94 95 95 … … 100 100 Used by ModelLogicBase decendants. 101 101 """ 102 pass; 103 104 105 class ModelBase(object): # pylint: disable= R0903102 pass; # pylint: disable=unnecessary-pass 103 104 105 class ModelBase(object): # pylint: disable=too-few-public-methods 106 106 """ 107 107 Something all classes in the logical model inherits from. … … 115 115 116 116 117 class ModelDataBase(ModelBase): # pylint: disable= R0903117 class ModelDataBase(ModelBase): # pylint: disable=too-few-public-methods 118 118 """ 119 119 Something all classes in the data classes in the logical model inherits from. … … 198 198 if sPrefix in ['id', 'uid', 'i', 'off', 'pct']: 199 199 return [-1, '', '-1',]; 200 elif sPrefix in ['l', 'c',]:200 if sPrefix in ['l', 'c',]: 201 201 return [long(-1), '', '-1',]; 202 elif sPrefix == 'f':202 if sPrefix == 'f': 203 203 return ['',]; 204 elif sPrefix in ['enm', 'ip', 's', 'ts', 'uuid']:204 if sPrefix in ['enm', 'ip', 's', 'ts', 'uuid']: 205 205 return ['',]; 206 elif sPrefix in ['ai', 'aid', 'al', 'as']:206 if sPrefix in ['ai', 'aid', 'al', 'as']: 207 207 return [[], '', None]; ## @todo ?? 208 elif sPrefix == 'bm':208 if sPrefix == 'bm': 209 209 return ['', [],]; ## @todo bitmaps. 210 210 raise TMExceptionBase('Unable to classify "%s" (prefix %s)' % (sAttr, sPrefix)); … … 370 370 371 371 # Check the NULL requirements of the primary ID(s) for the 'add' and 'edit' actions. 372 if enmValidateFor == ModelDataBase.ksValidateFor_Add \373 or enmValidateFor == ModelDataBase.ksValidateFor_AddForeignId \374 or enmValidateFor == ModelDataBase.ksValidateFor_Edit:372 if enmValidateFor in (ModelDataBase.ksValidateFor_Add, 373 ModelDataBase.ksValidateFor_AddForeignId, 374 ModelDataBase.ksValidateFor_Edit,): 375 375 fMustBeNull = enmValidateFor == ModelDataBase.ksValidateFor_Add; 376 376 sAttr = getattr(self, 'ksIdAttr', None); … … 572 572 if iValue < iMin: 573 573 return (iValue, 'Value too small (min %d)' % (iMin,)); 574 elif iValue > iMax:574 if iValue > iMax: 575 575 return (iValue, 'Value too high (max %d)' % (iMax,)); 576 576 return (iValue, None); … … 596 596 if lMin is not None and lValue < lMin: 597 597 return (lValue, 'Value too small (min %d)' % (lMin,)); 598 elif lMax is not None and lValue > lMax:598 if lMax is not None and lValue > lMax: 599 599 return (lValue, 'Value too high (max %d)' % (lMax,)); 600 600 return (lValue, None); … … 662 662 663 663 try: 664 socket.inet_pton(socket.AF_INET, sValue); # pylint: disable= E1101664 socket.inet_pton(socket.AF_INET, sValue); # pylint: disable=no-member 665 665 except: 666 666 try: 667 socket.inet_pton(socket.AF_INET6, sValue); # pylint: disable= E1101667 socket.inet_pton(socket.AF_INET6, sValue); # pylint: disable=no-member 668 668 except: 669 669 return (sValue, 'Not a valid IP address.'); … … 1067 1067 1068 1068 1069 # pylint: disable= E1101,C0111,R09031069 # pylint: disable=no-member,missing-docstring,too-few-public-methods 1070 1070 class ModelDataBaseTestCase(unittest.TestCase): 1071 1071 """ … … 1241 1241 def __init__(self): 1242 1242 ModelBase.__init__(self); 1243 self.aCriteria = [] ;# type: list[FilterCriterion]1243 self.aCriteria = [] # type: list[FilterCriterion] 1244 1244 1245 1245 def _initFromParamsWorker(self, oDisp, oCriterion): … … 1285 1285 1286 1286 1287 class ModelLogicBase(ModelBase): # pylint: disable= R09031287 class ModelLogicBase(ModelBase): # pylint: disable=too-few-public-methods 1288 1288 """ 1289 1289 Something all classes in the logic classes the logical model inherits from. … … 1328 1328 1329 1329 1330 class AttributeChangeEntry(object): # pylint: disable= R09031330 class AttributeChangeEntry(object): # pylint: disable=too-few-public-methods 1331 1331 """ 1332 1332 Data class representing the changes made to one attribute. … … 1340 1340 self.sOldText = sOldText; 1341 1341 1342 class AttributeChangeEntryPre(AttributeChangeEntry): # pylint: disable= R09031342 class AttributeChangeEntryPre(AttributeChangeEntry): # pylint: disable=too-few-public-methods 1343 1343 """ 1344 1344 AttributeChangeEntry for preformatted values. … … 1348 1348 AttributeChangeEntry.__init__(self, sAttr, oNewRaw, oOldRaw, sNewText, sOldText); 1349 1349 1350 class ChangeLogEntry(object): # pylint: disable= R09031350 class ChangeLogEntry(object): # pylint: disable=too-few-public-methods 1351 1351 """ 1352 1352 A change log entry returned by the fetchChangeLog method typically -
trunk/src/VBox/ValidationKit/testmanager/core/build.py
r76553 r79087 143 143 144 144 145 class BuildCategoryLogic(ModelLogicBase): # pylint: disable= R0903145 class BuildCategoryLogic(ModelLogicBase): # pylint: disable=too-few-public-methods 146 146 """ 147 147 Build categories database logic. … … 502 502 503 503 504 class BuildLogic(ModelLogicBase): # pylint: disable= R0903504 class BuildLogic(ModelLogicBase): # pylint: disable=too-few-public-methods 505 505 """ 506 506 Build database logic (covers build categories as well as builds). … … 867 867 # 868 868 869 # pylint: disable= C0111869 # pylint: disable=missing-docstring 870 870 class BuildCategoryDataTestCase(ModelDataBaseTestCase): 871 871 def setUp(self): -
trunk/src/VBox/ValidationKit/testmanager/core/buildblacklist.py
r76553 r79087 119 119 120 120 121 class BuildBlacklistLogic(ModelLogicBase): # pylint: disable= R0903121 class BuildBlacklistLogic(ModelLogicBase): # pylint: disable=too-few-public-methods 122 122 """ 123 123 Build Back List logic. -
trunk/src/VBox/ValidationKit/testmanager/core/buildsource.py
r76553 r79087 150 150 return (oNewValue, sError); 151 151 152 class BuildSourceLogic(ModelLogicBase): # pylint: disable= R0903152 class BuildSourceLogic(ModelLogicBase): # pylint: disable=too-few-public-methods 153 153 """ 154 154 Build source database logic. … … 504 504 # 505 505 506 # pylint: disable= C0111506 # pylint: disable=missing-docstring 507 507 class BuildSourceDataTestCase(ModelDataBaseTestCase): 508 508 def setUp(self): -
trunk/src/VBox/ValidationKit/testmanager/core/db.py
r76553 r79087 214 214 if config.g_ksDatabasePort is not None: 215 215 dArgs['port'] = config.g_ksDatabasePort; 216 self._oConn = psycopg2.connect(**dArgs); # pylint: disable= W0142216 self._oConn = psycopg2.connect(**dArgs); # pylint: disable=star-args 217 217 self._oConn.set_client_encoding('UTF-8'); 218 218 self._oCursor = self._oConn.cursor(); … … 220 220 self._oExplainCursor = None; 221 221 if config.g_kfWebUiSqlTraceExplain and config.g_kfWebUiSqlTrace: 222 self._oExplainConn = psycopg2.connect(**dArgs); # pylint: disable= W0142222 self._oExplainConn = psycopg2.connect(**dArgs); # pylint: disable=star-args 223 223 self._oExplainConn.set_client_encoding('UTF-8'); 224 224 self._oExplainCursor = self._oExplainConn.cursor(); … … 701 701 if config.g_ksDatabasePort is not None: 702 702 dArgs['port'] = config.g_ksDatabasePort; 703 self._oExplainConn = psycopg2.connect(**dArgs); # pylint: disable= W0142703 self._oExplainConn = psycopg2.connect(**dArgs); # pylint: disable=star-args 704 704 self._oExplainCursor = self._oExplainConn.cursor(); 705 705 return True; -
trunk/src/VBox/ValidationKit/testmanager/core/failurecategory.py
r76553 r79087 109 109 110 110 111 class FailureCategoryLogic(ModelLogicBase): # pylint: disable= R0903111 class FailureCategoryLogic(ModelLogicBase): # pylint: disable=too-few-public-methods 112 112 """ 113 113 Failure Category logic. … … 149 149 150 150 151 def fetchForChangeLog(self, idFailureCategory, iStart, cMaxRows, tsNow): # pylint: disable= R0914151 def fetchForChangeLog(self, idFailureCategory, iStart, cMaxRows, tsNow): # pylint: disable=too-many-locals 152 152 """ 153 153 Fetches change log entries for a failure reason. -
trunk/src/VBox/ValidationKit/testmanager/core/failurereason.py
r76553 r79087 143 143 144 144 145 class FailureReasonLogic(ModelLogicBase): # pylint: disable= R0903145 class FailureReasonLogic(ModelLogicBase): # pylint: disable=too-few-public-methods 146 146 """ 147 147 Failure Reason logic. … … 276 276 277 277 278 def fetchForChangeLog(self, idFailureReason, iStart, cMaxRows, tsNow): # pylint: disable= R0914278 def fetchForChangeLog(self, idFailureReason, iStart, cMaxRows, tsNow): # pylint: disable=too-many-locals 279 279 """ 280 280 Fetches change log entries for a failure reason. -
trunk/src/VBox/ValidationKit/testmanager/core/globalresource.py
r76553 r79087 308 308 # 309 309 310 # pylint: disable= C0111310 # pylint: disable=missing-docstring 311 311 class GlobalResourceDataTestCase(ModelDataBaseTestCase): 312 312 def setUp(self): -
trunk/src/VBox/ValidationKit/testmanager/core/report.py
r76553 r79087 60 60 61 61 62 class ReportModelBase(ModelLogicBase): # pylint: disable= R090362 class ReportModelBase(ModelLogicBase): # pylint: disable=too-few-public-methods 63 63 """ 64 64 Something all report logic(/miner) classes inherit from. … … 242 242 class ReportFailureReasonTransient(ReportTransientBase): 243 243 """ Details on the test where a failure reason was first/last seen. """ 244 def __init__(self, idBuild, iRevision, sRepository, idTestSet, idTestResult, tsDone, # pylint: disable= R0913244 def __init__(self, idBuild, iRevision, sRepository, idTestSet, idTestResult, tsDone, # pylint: disable=too-many-arguments 245 245 iPeriod, fEnter, oReason): 246 246 ReportTransientBase.__init__(self, idBuild, iRevision, sRepository, idTestSet, idTestResult, tsDone, iPeriod, fEnter, … … 530 530 531 531 532 class ReportLazyModel(ReportModelBase): # pylint: disable= R0903532 class ReportLazyModel(ReportModelBase): # pylint: disable=too-few-public-methods 533 533 """ 534 534 The 'lazy bird' report model class. … … 890 890 891 891 892 class ReportGraphModel(ReportModelBase): # pylint: disable= R0903892 class ReportGraphModel(ReportModelBase): # pylint: disable=too-few-public-methods 893 893 """ 894 894 Extended report model used when generating the more complicated graphs … … 977 977 978 978 979 def __init__(self, oDb, tsNow, cPeriods, cHoursPerPeriod, sSubject, aidSubjects, # pylint: disable= R0913979 def __init__(self, oDb, tsNow, cPeriods, cHoursPerPeriod, sSubject, aidSubjects, # pylint: disable=too-many-arguments 980 980 aidTestBoxes, aidBuildCats, aidTestCases, fSepTestVars): 981 981 assert(sSubject == self.ksSubEverything); # dummy -
trunk/src/VBox/ValidationKit/testmanager/core/schedgroup.py
r76553 r79087 259 259 def __init__(self): 260 260 SchedGroupData.__init__(self); 261 self.aoMembers = [] ;# type: SchedGroupMemberDataEx261 self.aoMembers = [] # type: SchedGroupMemberDataEx 262 262 263 263 # Two build sources for convenience sake. 264 self.oBuildSrc = None ;# type: TestBoxData265 self.oBuildSrcValidationKit = None ;# type: TestBoxData264 self.oBuildSrc = None # type: TestBoxData 265 self.oBuildSrcValidationKit = None # type: TestBoxData 266 266 # List of test boxes that uses this group for convenience. 267 self.aoTestBoxes = None ;# type: list[TestBoxData]267 self.aoTestBoxes = None # type: list[TestBoxData] 268 268 269 269 def _initExtraMembersFromDb(self, oDb, tsNow = None, sPeriodBack = None): … … 421 421 422 422 423 class SchedGroupLogic(ModelLogicBase): # pylint: disable= R0903423 class SchedGroupLogic(ModelLogicBase): # pylint: disable=too-few-public-methods 424 424 """ 425 425 SchedGroup logic. … … 578 578 raise TMRowInUse('Scheduling group #%d is associated with one or more test boxes: %s' 579 579 % (idSchedGroup, ', '.join(asTestBoxes),)); 580 else: 581 # Reassign testboxes to scheduling group #1 (the default group). 582 oTbLogic = TestBoxLogic(self._oDb); 583 for oTestBox in oData.aoTestBoxes: 584 oTbCopy = TestBoxData().initFromOther(oTestBox); 585 oTbCopy.idSchedGroup = 1; 586 oTbLogic.editEntry(oTbCopy, uidAuthor, fCommit = False); 587 588 oData = SchedGroupDataEx().initFromDbWithId(self._oDb, idSchedGroup); 589 if oData.aoTestBoxes: 590 raise TMRowInUse('More testboxes was added to the scheduling group as we were trying to delete it.'); 580 # Reassign testboxes to scheduling group #1 (the default group). 581 oTbLogic = TestBoxLogic(self._oDb); 582 for oTestBox in oData.aoTestBoxes: 583 oTbCopy = TestBoxData().initFromOther(oTestBox); 584 oTbCopy.idSchedGroup = 1; 585 oTbLogic.editEntry(oTbCopy, uidAuthor, fCommit = False); 586 587 oData = SchedGroupDataEx().initFromDbWithId(self._oDb, idSchedGroup); 588 if oData.aoTestBoxes: 589 raise TMRowInUse('More testboxes was added to the scheduling group as we were trying to delete it.'); 591 590 592 591 # … … 982 981 # 983 982 984 # pylint: disable= C0111983 # pylint: disable=missing-docstring 985 984 class SchedGroupMemberDataTestCase(ModelDataBaseTestCase): 986 985 def setUp(self): -
trunk/src/VBox/ValidationKit/testmanager/core/schedulerbase.py
r76553 r79087 1 1 # -*- coding: utf-8 -*- 2 2 # $Id$ 3 # pylint: disable= C03023 # pylint: disable=too-many-lines 4 4 5 5 … … 352 352 self.cMissingGangMembers = 1; 353 353 354 def initFromValues(self, idSchedGroup, idGenTestCaseArgs, idTestGroup, aidTestGroupPreReqs, # pylint: disable= R0913354 def initFromValues(self, idSchedGroup, idGenTestCaseArgs, idTestGroup, aidTestGroupPreReqs, # pylint: disable=too-many-arguments 355 355 bmHourlySchedule, cMissingGangMembers, 356 356 idItem = None, offQueue = None, tsConfig = None, tsLastScheduled = None, idTestSetGangLeader = None): … … 1506 1506 # 1507 1507 1508 # pylint: disable= C01111508 # pylint: disable=missing-docstring 1509 1509 class SchedQueueDataTestCase(ModelDataBaseTestCase): 1510 1510 def setUp(self): -
trunk/src/VBox/ValidationKit/testmanager/core/schedulerbeci.py
r76553 r79087 34 34 35 35 36 class SchdulerBeci(SchedulerBase): # pylint: disable= R090336 class SchdulerBeci(SchedulerBase): # pylint: disable=too-few-public-methods 37 37 """ 38 38 The best-effort-continuous-integration scheduler, BECI for short. -
trunk/src/VBox/ValidationKit/testmanager/core/systemchangelog.py
r76553 r79087 36 36 37 37 38 class SystemChangelogEntry(object): # pylint: disable= R090238 class SystemChangelogEntry(object): # pylint: disable=too-many-instance-attributes 39 39 """ 40 40 System changelog entry. … … 71 71 72 72 ## Mapping a changelog entry kind to a table, key and clue. 73 kdWhatToTable = dict({ # pylint: disable= W014273 kdWhatToTable = dict({ # pylint: disable=star-args 74 74 ksWhat_TestBox: ( 'TestBoxes', 'idTestBox', None, ), 75 75 ksWhat_TestCase: ( 'TestCasees', 'idTestCase', None, ), -
trunk/src/VBox/ValidationKit/testmanager/core/systemlog.py
r76553 r79087 37 37 38 38 39 class SystemLogData(ModelDataBase): # pylint: disable= R090239 class SystemLogData(ModelDataBase): # pylint: disable=too-many-instance-attributes 40 40 """ 41 41 SystemLog Data. … … 166 166 # 167 167 168 # pylint: disable= C0111168 # pylint: disable=missing-docstring 169 169 class SystemLogDataTestCase(ModelDataBaseTestCase): 170 170 def setUp(self): -
trunk/src/VBox/ValidationKit/testmanager/core/testbox.py
r76886 r79087 99 99 def __init__(self): 100 100 TestBoxInSchedGroupData.__init__(self); 101 self.oSchedGroup = None ;# type: SchedGroupData101 self.oSchedGroup = None # type: SchedGroupData 102 102 103 103 def initFromDbRowEx(self, aoRow, oDb, tsNow = None, sPeriodBack = None): … … 111 111 112 112 113 # pylint: disable= C0103114 class TestBoxData(ModelDataBase): # pylint: disable= R0902113 # pylint: disable=invalid-name 114 class TestBoxData(ModelDataBase): # pylint: disable=too-many-instance-attributes 115 115 """ 116 116 TestBox Data. … … 476 476 if uFam == 0xf: 477 477 if uMod < 0x10: return 'K8_130nm'; 478 if uMod >= 0x60 and uMod < 0x80:return 'K8_65nm';478 if 0x60 <= uMod < 0x80: return 'K8_65nm'; 479 479 if uMod >= 0x40: return 'K8_90nm_AMDV'; 480 480 if uMod in [0x21, 0x23, 0x2b, 0x37, 0x3f]: return 'K8_90nm_DualCore'; … … 567 567 def __init__(self): 568 568 TestBoxData.__init__(self); 569 self.aoInSchedGroups = [] ;# type: list[TestBoxInSchedGroupData]569 self.aoInSchedGroups = [] # type: list[TestBoxInSchedGroupData] 570 570 571 571 def _initExtraMembersFromDb(self, oDb, tsNow = None, sPeriodBack = None): … … 634 634 return aoNewValues; 635 635 636 def _validateAndConvertAttribute(self, sAttr, sParam, oValue, aoNilValues, fAllowNull, oDb): # pylint: disable= R0914636 def _validateAndConvertAttribute(self, sAttr, sParam, oValue, aoNilValues, fAllowNull, oDb): # pylint: disable=too-many-locals 637 637 """ 638 638 Validate special arrays and requirement expressions. … … 773 773 TestBoxDataEx.__init__(self); 774 774 self.tsCurrent = None; # CURRENT_TIMESTAMP 775 self.oStatus = None ;# type: TestBoxStatusData775 self.oStatus = None # type: TestBoxStatusData 776 776 777 777 from testmanager.core.testboxstatus import TestBoxStatusData; … … 811 811 return aoRows; 812 812 813 def fetchForChangeLog(self, idTestBox, iStart, cMaxRows, tsNow): # pylint: disable= R0914813 def fetchForChangeLog(self, idTestBox, iStart, cMaxRows, tsNow): # pylint: disable=too-many-locals 814 814 """ 815 815 Fetches change log entries for a testbox. … … 1013 1013 1014 1014 1015 def updateOnSignOn(self, idTestBox, idGenTestBox, sTestBoxAddr, sOs, sOsVersion, # pylint: disable= R0913,R09141015 def updateOnSignOn(self, idTestBox, idGenTestBox, sTestBoxAddr, sOs, sOsVersion, # pylint: disable=too-many-arguments,too-many-locals 1016 1016 sCpuVendor, sCpuArch, sCpuName, lCpuRevision, cCpus, fCpuHwVirt, fCpuNestedPaging, fCpu64BitGuest, 1017 1017 fChipsetIoMmu, fRawMode, cMbMemory, cMbScratch, sReport, iTestBoxScriptRev, iPythonHexVersion): … … 1153 1153 except TMInFligthCollision: 1154 1154 return False; 1155 except:1156 raise;1157 1155 return True; 1158 1156 … … 1177 1175 # 1178 1176 1179 # pylint: disable= C01111177 # pylint: disable=missing-docstring 1180 1178 class TestBoxDataTestCase(ModelDataBaseTestCase): 1181 1179 def setUp(self): -
trunk/src/VBox/ValidationKit/testmanager/core/testboxcontroller.py
r76553 r79087 33 33 import re; 34 34 import os; 35 import string; # pylint: disable= W040235 import string; # pylint: disable=deprecated-module 36 36 import sys; 37 37 import uuid; … … 53 53 # Python 3 hacks: 54 54 if sys.version_info[0] >= 3: 55 long = int; # pylint: disable= W0622,C010355 long = int; # pylint: disable=redefined-builtin,invalid-name 56 56 57 57 … … 60 60 Exception class for TestBoxController. 61 61 """ 62 pass; 63 64 65 class TestBoxController(object): # pylint: disable= R090362 pass; # pylint: disable=unnecessary-pass 63 64 65 class TestBoxController(object): # pylint: disable=too-few-public-methods 66 66 """ 67 67 TestBox Controller class. … … 190 190 """ 191 191 sValue = self._getStringParam(sName, [ 'True', 'true', '1', 'False', 'false', '0'], sDefValue = str(fDefValue)); 192 return sValue == 'True' or sValue == 'true' or sValue == '1';192 return sValue in ('True', 'true', '1',); 193 193 194 194 def _getIntParam(self, sName, iMin = None, iMax = None): … … 346 346 return fSizeOk; 347 347 348 def _actionSignOn(self): # pylint: disable= R0914348 def _actionSignOn(self): # pylint: disable=too-many-locals 349 349 """ Implement sign-on """ 350 350 … … 401 401 cPctScratchDiff = 100; 402 402 403 # pylint: disable= R0916403 # pylint: disable=too-many-boolean-expressions 404 404 if self._sTestBoxAddr != oTestBox.ip \ 405 405 or sOs != oTestBox.sOs \ … … 738 738 739 739 abBuf = oSrcFile.read(cbToRead); 740 oDstFile.write(abBuf); # pylint: disable= E1103740 oDstFile.write(abBuf); # pylint: disable=maybe-no-member 741 741 del abBuf; 742 742 743 oDstFile.close(); # pylint: disable= E1103743 oDstFile.close(); # pylint: disable=maybe-no-member 744 744 745 745 # Done. -
trunk/src/VBox/ValidationKit/testmanager/core/testboxstatus.py
r76553 r79087 297 297 # 298 298 299 # pylint: disable= C0111299 # pylint: disable=missing-docstring 300 300 class TestBoxStatusDataTestCase(ModelDataBaseTestCase): 301 301 def setUp(self): -
trunk/src/VBox/ValidationKit/testmanager/core/testcase.py
r76553 r79087 1 1 # -*- coding: utf-8 -*- 2 2 # $Id$ 3 # pylint: disable= C03023 # pylint: disable=too-many-lines 4 4 5 5 """ … … 857 857 return aoNewValues; 858 858 859 def _validateAndConvertAttribute(self, sAttr, sParam, oValue, aoNilValues, fAllowNull, oDb): # pylint: disable= R0914859 def _validateAndConvertAttribute(self, sAttr, sParam, oValue, aoNilValues, fAllowNull, oDb): # pylint: disable=too-many-locals 860 860 """ 861 861 Validate special arrays and requirement expressions. … … 999 999 return aoRows; 1000 1000 1001 def fetchForChangeLog(self, idTestCase, iStart, cMaxRows, tsNow): # pylint: disable= R09141001 def fetchForChangeLog(self, idTestCase, iStart, cMaxRows, tsNow): # pylint: disable=too-many-locals 1002 1002 """ 1003 1003 Fetches change log entries for a testbox. … … 1184 1184 return True; 1185 1185 1186 def editEntry(self, oData, uidAuthor, fCommit = False): # pylint: disable= R09141186 def editEntry(self, oData, uidAuthor, fCommit = False): # pylint: disable=too-many-locals 1187 1187 """ 1188 1188 Edit a testcase entry (extended). … … 1416 1416 # 1417 1417 1418 # pylint: disable= C01111418 # pylint: disable=missing-docstring 1419 1419 class TestCaseGlobalRsrcDepDataTestCase(ModelDataBaseTestCase): 1420 1420 def setUp(self): -
trunk/src/VBox/ValidationKit/testmanager/core/testcaseargs.py
r76553 r79087 42 42 # Python 3 hacks: 43 43 if sys.version_info[0] >= 3: 44 long = int; # pylint: disable= W0622,C010344 long = int; # pylint: disable=redefined-builtin,invalid-name 45 45 46 46 … … 135 135 return self.initFromDbRow(oDb.fetchOne()); 136 136 137 def initFromValues(self, sArgs, cSecTimeout = None, sTestBoxReqExpr = None, sBuildReqExpr = None, # pylint: disable= R0913137 def initFromValues(self, sArgs, cSecTimeout = None, sTestBoxReqExpr = None, sBuildReqExpr = None, # pylint: disable=too-many-arguments 138 138 cGangMembers = 1, idTestCase = None, idTestCaseArgs = None, tsEffective = None, tsExpire = None, 139 139 uidAuthor = None, idGenTestCaseArgs = None, sSubName = None): … … 396 396 # 397 397 398 # pylint: disable= C0111398 # pylint: disable=missing-docstring 399 399 class TestCaseArgsDataTestCase(ModelDataBaseTestCase): 400 400 def setUp(self): -
trunk/src/VBox/ValidationKit/testmanager/core/testgroup.py
r76553 r79087 747 747 # 748 748 749 # pylint: disable= C0111749 # pylint: disable=missing-docstring 750 750 class TestGroupMemberDataTestCase(ModelDataBaseTestCase): 751 751 def setUp(self): -
trunk/src/VBox/ValidationKit/testmanager/core/testresultfailures.py
r76553 r79087 1 1 # -*- coding: utf-8 -*- 2 2 # $Id$ 3 # pylint: disable= C03023 # pylint: disable=too-many-lines 4 4 5 5 ## @todo Rename this file to testresult.py! … … 146 146 147 147 148 class TestResultListingData(ModelDataBase): # pylint: disable= R0902148 class TestResultListingData(ModelDataBase): # pylint: disable=too-many-instance-attributes 149 149 """ 150 150 Test case result data representation for table listing … … 255 255 256 256 257 class TestResultFailureLogic(ModelLogicBase): # pylint: disable= R0903257 class TestResultFailureLogic(ModelLogicBase): # pylint: disable=too-few-public-methods 258 258 """ 259 259 Test result failure reason logic. … … 263 263 ModelLogicBase.__init__(self, oDb) 264 264 265 def fetchForChangeLog(self, idTestResult, iStart, cMaxRows, tsNow): # pylint: disable= R0914265 def fetchForChangeLog(self, idTestResult, iStart, cMaxRows, tsNow): # pylint: disable=too-many-locals 266 266 """ 267 267 Fetches change log entries for a failure reason. … … 509 509 # 510 510 511 # pylint: disable= C0111511 # pylint: disable=missing-docstring 512 512 class TestResultFailureDataTestCase(ModelDataBaseTestCase): 513 513 def setUp(self): -
trunk/src/VBox/ValidationKit/testmanager/core/testresults.py
r76553 r79087 1 1 # -*- coding: utf-8 -*- 2 2 # $Id$ 3 # pylint: disable= C03023 # pylint: disable=too-many-lines 4 4 5 5 ## @todo Rename this file to testresult.py! … … 550 550 551 551 552 class TestResultListingData(ModelDataBase): # pylint: disable= R0902552 class TestResultListingData(ModelDataBase): # pylint: disable=too-many-instance-attributes 553 553 """ 554 554 Test case result data representation for table listing … … 990 990 991 991 992 class TestResultLogic(ModelLogicBase): # pylint: disable= R0903992 class TestResultLogic(ModelLogicBase): # pylint: disable=too-few-public-methods 993 993 """ 994 994 Results grouped by scheduling group. … … 1199 1199 return sRet 1200 1200 1201 def fetchResultsForListing(self, iStart, cMaxRows, tsNow, sInterval, oFilter, enmResultSortBy, # pylint: disable= R09131201 def fetchResultsForListing(self, iStart, cMaxRows, tsNow, sInterval, oFilter, enmResultSortBy, # pylint: disable=too-many-arguments 1202 1202 enmResultsGroupingType, iResultsGroupingValue, fOnlyFailures, fOnlyNeedingReason): 1203 1203 """ … … 2558 2558 if sAttr in dAttribs: 2559 2559 try: 2560 _ = long(dAttribs[sAttr]); # pylint: disable= R02042560 _ = long(dAttribs[sAttr]); # pylint: disable=redefined-variable-type 2561 2561 except: 2562 2562 return 'Element %s has an invalid %s attribute value: %s.' % (sName, sAttr, dAttribs[sAttr],); … … 2854 2854 # 2855 2855 2856 # pylint: disable= C01112856 # pylint: disable=missing-docstring 2857 2857 class TestResultDataTestCase(ModelDataBaseTestCase): 2858 2858 def setUp(self): -
trunk/src/VBox/ValidationKit/testmanager/core/testset.py
r78780 r79087 537 537 return True; 538 538 539 def createFile(self, oTestSet, sName, sMime, sKind, sDesc, cbFile, fCommit = False): # pylint: disable= R0914539 def createFile(self, oTestSet, sName, sMime, sKind, sDesc, cbFile, fCommit = False): # pylint: disable=too-many-locals 540 540 """ 541 541 Creates a file and associating with the current test result record in … … 825 825 # 826 826 827 # pylint: disable= C0111827 # pylint: disable=missing-docstring 828 828 class TestSetDataTestCase(ModelDataBaseTestCase): 829 829 def setUp(self): -
trunk/src/VBox/ValidationKit/testmanager/core/useraccount.py
r76553 r79087 282 282 # 283 283 284 # pylint: disable= C0111284 # pylint: disable=missing-docstring 285 285 class UserAccountDataTestCase(ModelDataBaseTestCase): 286 286 def setUp(self): -
trunk/src/VBox/ValidationKit/testmanager/core/vcsrevisions.py
r76553 r79087 105 105 106 106 107 class VcsRevisionLogic(ModelLogicBase): # pylint: disable= R0903107 class VcsRevisionLogic(ModelLogicBase): # pylint: disable=too-few-public-methods 108 108 """ 109 109 VCS revisions database logic. … … 234 234 # 235 235 236 # pylint: disable= C0111236 # pylint: disable=missing-docstring 237 237 class VcsRevisionDataTestCase(ModelDataBaseTestCase): 238 238 def setUp(self): -
trunk/src/VBox/ValidationKit/testmanager/db/partial-db-dump.py
r76553 r79087 2 2 # -*- coding: utf-8 -*- 3 3 # $Id$ 4 # pylint: disable= C03014 # pylint: disable=line-too-long 5 5 6 6 """ … … 47 47 48 48 49 class PartialDbDump(object): # pylint: disable= R090349 class PartialDbDump(object): # pylint: disable=too-few-public-methods 50 50 """ 51 51 Dumps or loads the last X days of database data. -
trunk/src/VBox/ValidationKit/testmanager/webui/wuiadmin.py
r76553 r79087 812 812 self.ksActionGlobalRsrcShowAll); 813 813 814 def _actionGlobalRsrcShowAddEdit(self, sAction): # pylint: disable= C0103814 def _actionGlobalRsrcShowAddEdit(self, sAction): # pylint: disable=invalid-name 815 815 """Show Global Resource creation or edit dialog""" 816 816 from testmanager.core.globalresource import GlobalResourceLogic, GlobalResourceData; -
trunk/src/VBox/ValidationKit/testmanager/webui/wuiadmintestbox.py
r76553 r79087 239 239 return (sTitle, sBody); 240 240 241 def _formatListEntry(self, iEntry): # pylint: disable= R0914241 def _formatListEntry(self, iEntry): # pylint: disable=too-many-locals 242 242 from testmanager.webui.wuiadmin import WuiAdmin; 243 243 oEntry = self._aoEntries[iEntry]; … … 274 274 else: 275 275 from testmanager.webui.wuimain import WuiMain; 276 oState = WuiTmLink(oEntry.oStatus.enmState, WuiMain.ksScriptName, # pylint: disable= R0204276 oState = WuiTmLink(oEntry.oStatus.enmState, WuiMain.ksScriptName, # pylint: disable=redefined-variable-type 277 277 { WuiMain.ksParamAction: WuiMain.ksActionTestResultDetails, 278 278 TestSetData.ksParam_idTestSet: oEntry.oStatus.idTestSet, }, -
trunk/src/VBox/ValidationKit/testmanager/webui/wuibase.py
r76553 r79087 523 523 return asValues; 524 524 525 def getListOfTestCasesParam(self, sName, asDefaults = None): # too many local vars - pylint: disable= R0914525 def getListOfTestCasesParam(self, sName, asDefaults = None): # too many local vars - pylint: disable=too-many-locals 526 526 """Get list of test cases and their parameters""" 527 527 if sName in self._dParams: … … 855 855 return True 856 856 857 def _actionGenericFormDetails(self, oDataType, oLogicType, oFormType, sIdAttr = None, sGenIdAttr = None): # pylint: disable= R0914857 def _actionGenericFormDetails(self, oDataType, oLogicType, oFormType, sIdAttr = None, sGenIdAttr = None): # pylint: disable=too-many-locals 858 858 """ 859 859 Generic handler for showing a details form/page. -
trunk/src/VBox/ValidationKit/testmanager/webui/wuicontentbase.py
r76553 r79087 47 47 48 48 49 class WuiHtmlBase(object): # pylint: disable= R090349 class WuiHtmlBase(object): # pylint: disable=too-few-public-methods 50 50 """ 51 51 Base class for HTML objects. … … 69 69 70 70 71 class WuiLinkBase(WuiHtmlBase): # pylint: disable= R090371 class WuiLinkBase(WuiHtmlBase): # pylint: disable=too-few-public-methods 72 72 """ 73 73 For passing links from WuiListContentBase._formatListEntry. … … 118 118 119 119 120 class WuiTmLink(WuiLinkBase): # pylint: disable= R0903120 class WuiTmLink(WuiLinkBase): # pylint: disable=too-few-public-methods 121 121 """ Local link to the test manager. """ 122 122 … … 139 139 140 140 141 class WuiAdminLink(WuiTmLink): # pylint: disable= R0903141 class WuiAdminLink(WuiTmLink): # pylint: disable=too-few-public-methods 142 142 """ Local link to the test manager's admin portion. """ 143 143 … … 156 156 sFragmentId = sFragmentId, fBracketed = fBracketed); 157 157 158 class WuiMainLink(WuiTmLink): # pylint: disable= R0903158 class WuiMainLink(WuiTmLink): # pylint: disable=too-few-public-methods 159 159 """ Local link to the test manager's main portion. """ 160 160 … … 170 170 sFragmentId = sFragmentId, fBracketed = fBracketed); 171 171 172 class WuiSvnLink(WuiLinkBase): # pylint: disable= R0903172 class WuiSvnLink(WuiLinkBase): # pylint: disable=too-few-public-methods 173 173 """ 174 174 For linking to a SVN revision. … … 180 180 fBracketed = fBracketed, sExtraAttrs = sExtraAttrs); 181 181 182 class WuiSvnLinkWithTooltip(WuiSvnLink): # pylint: disable= R0903182 class WuiSvnLinkWithTooltip(WuiSvnLink): # pylint: disable=too-few-public-methods 183 183 """ 184 184 For linking to a SVN revision with changelog tooltip. … … 202 202 WuiLinkBase.__init__(self, sName, sUrl, fBracketed = fBracketed); 203 203 204 class WuiRawHtml(WuiHtmlBase): # pylint: disable= R0903204 class WuiRawHtml(WuiHtmlBase): # pylint: disable=too-few-public-methods 205 205 """ 206 206 For passing raw html from WuiListContentBase._formatListEntry. … … 213 213 return self.sHtml; 214 214 215 class WuiHtmlKeeper(WuiHtmlBase): # pylint: disable= R0903215 class WuiHtmlKeeper(WuiHtmlBase): # pylint: disable=too-few-public-methods 216 216 """ 217 217 For keeping a list of elements, concatenating their toHtml output together. … … 238 238 return self.sSep.join(oObj.toHtml() for oObj in self.aoKept); 239 239 240 class WuiSpanText(WuiRawHtml): # pylint: disable= R0903240 class WuiSpanText(WuiRawHtml): # pylint: disable=too-few-public-methods 241 241 """ 242 242 Outputs the given text within a span of the given CSS class. … … 252 252 % ( webutils.escapeAttr(sSpanClass), webutils.escapeAttr(sTitle), webutils.escapeElem(sText),)); 253 253 254 class WuiElementText(WuiRawHtml): # pylint: disable= R0903254 class WuiElementText(WuiRawHtml): # pylint: disable=too-few-public-methods 255 255 """ 256 256 Outputs the given element text. … … 260 260 261 261 262 class WuiContentBase(object): # pylint: disable= R0903262 class WuiContentBase(object): # pylint: disable=too-few-public-methods 263 263 """ 264 264 Base for the content classes. … … 382 382 return sHtml; 383 383 384 class WuiSingleContentBase(WuiContentBase): # pylint: disable= R0903384 class WuiSingleContentBase(WuiContentBase): # pylint: disable=too-few-public-methods 385 385 """ 386 386 Base for the content classes working on a single data object (oData). … … 391 391 392 392 393 class WuiFormContentBase(WuiSingleContentBase): # pylint: disable= R0903393 class WuiFormContentBase(WuiSingleContentBase): # pylint: disable=too-few-public-methods 394 394 """ 395 395 Base class for simple input form content classes (single data object). -
trunk/src/VBox/ValidationKit/testmanager/webui/wuihlpform.py
r76553 r79087 415 415 sExtraAttribs = sExtraAttribs); 416 416 417 def addListOfTestCaseArgs(self, sName, aoVariations, sLabel): # pylint: disable= R0915417 def addListOfTestCaseArgs(self, sName, aoVariations, sLabel): # pylint: disable=too-many-statements 418 418 """ 419 419 Adds a list of test case argument variations to the form. … … 646 646 return self._add(sHtml) 647 647 648 def addListOfTestGroupMembers(self, sName, aoTestGroupMembers, aoAllTestCases, sLabel, # pylint: disable= R0914648 def addListOfTestGroupMembers(self, sName, aoTestGroupMembers, aoAllTestCases, sLabel, # pylint: disable=too-many-locals 649 649 fReadOnly = True): 650 650 """ … … 763 763 u'</table>\n'); 764 764 765 def addListOfSchedGroupMembers(self, sName, aoSchedGroupMembers, aoAllTestGroups, # pylint: disable= R0914765 def addListOfSchedGroupMembers(self, sName, aoSchedGroupMembers, aoAllTestGroups, # pylint: disable=too-many-locals 766 766 sLabel, fReadOnly = True): 767 767 """ … … 862 862 u'</table>\n'); 863 863 864 def addListOfSchedGroupsForTestBox(self, sName, aoInSchedGroups, aoAllSchedGroups, sLabel, # pylint: disable= R0914864 def addListOfSchedGroupsForTestBox(self, sName, aoInSchedGroups, aoAllSchedGroups, sLabel, # pylint: disable=too-many-locals 865 865 fReadOnly = None): 866 866 # type: (str, TestBoxInSchedGroupDataEx, SchedGroupData, str, bool) -> str -
trunk/src/VBox/ValidationKit/testmanager/webui/wuihlpgraph.py
r76553 r79087 30 30 31 31 32 class WuiHlpGraphDataTable(object): # pylint: disable= R090332 class WuiHlpGraphDataTable(object): # pylint: disable=too-few-public-methods 33 33 """ 34 34 Data table container. 35 35 """ 36 36 37 class Row(object): # pylint: disable= R090337 class Row(object): # pylint: disable=too-few-public-methods 38 38 """A row.""" 39 39 def __init__(self, sGroup, aoValues, asValues = None): … … 59 59 60 60 61 class WuiHlpGraphDataTableEx(object): # pylint: disable= R090361 class WuiHlpGraphDataTableEx(object): # pylint: disable=too-few-public-methods 62 62 """ 63 63 Data container for an table/graph with optional error bars on the Y values. 64 64 """ 65 65 66 class DataSeries(object): # pylint: disable= R090366 class DataSeries(object): # pylint: disable=too-few-public-methods 67 67 """ 68 68 A data series. … … 100 100 # Dynamically choose implementation. 101 101 # 102 if True: # pylint: disable= W0125102 if True: # pylint: disable=using-constant-test 103 103 from testmanager.webui import wuihlpgraphgooglechart as GraphImplementation; 104 104 else: 105 105 try: 106 import matplotlib; # pylint: disable= W0611,F0401,import-error,wrong-import-order106 import matplotlib; # pylint: disable=unused-import,import-error,import-error,wrong-import-order 107 107 from testmanager.webui import wuihlpgraphmatplotlib as GraphImplementation; # pylint: disable=ungrouped-imports 108 108 except: 109 109 from testmanager.webui import wuihlpgraphsimple as GraphImplementation; 110 110 111 # pylint: disable= C0103111 # pylint: disable=invalid-name 112 112 WuiHlpBarGraph = GraphImplementation.WuiHlpBarGraph; 113 113 WuiHlpLineGraph = GraphImplementation.WuiHlpLineGraph; -
trunk/src/VBox/ValidationKit/testmanager/webui/wuihlpgraphgooglechart.py
r76553 r79087 68 68 return True; 69 69 70 def renderGraph(self): # pylint: disable= R091470 def renderGraph(self): # pylint: disable=too-many-locals 71 71 fSlideFilter = True; 72 72 -
trunk/src/VBox/ValidationKit/testmanager/webui/wuihlpgraphmatplotlib.py
r76553 r79087 37 37 from StringIO import StringIO as StringIO; # pylint: disable=import-error,no-name-in-module 38 38 39 import matplotlib; # pylint: disable= F040139 import matplotlib; # pylint: disable=import-error 40 40 matplotlib.use('Agg'); # Force backend. 41 import matplotlib.pyplot; # pylint: disable= F040142 from numpy import arange as numpy_arange; # pylint: disable= E0611,E0401,wrong-import-order41 import matplotlib.pyplot; # pylint: disable=import-error 42 from numpy import arange as numpy_arange; # pylint: disable=no-name-in-module,import-error,wrong-import-order 43 43 44 44 # Validation Kit imports. … … 64 64 """ 65 65 if self._fXkcdStyle and matplotlib.__version__ > '1.2.9': 66 matplotlib.pyplot.xkcd(); # pylint: disable= E110166 matplotlib.pyplot.xkcd(); # pylint: disable=no-member 67 67 matplotlib.rcParams.update({'font.size': self._cPtFont}); 68 68 … … 106 106 return None; 107 107 108 def renderGraph(self): # pylint: disable= R0914108 def renderGraph(self): # pylint: disable=too-many-locals 109 109 aoTable = self._oData.aoTable; 110 110 … … 198 198 return True; 199 199 200 def renderGraph(self): # pylint: disable= R0914200 def renderGraph(self): # pylint: disable=too-many-locals 201 201 aoSeries = self._oData.aoSeries; 202 202 … … 246 246 oSubPlot.grid(True, 'both', axis = 'x'); 247 247 248 if True: # pylint: disable= W0125248 if True: # pylint: disable=using-constant-test 249 249 # oSubPlot.axis('off'); 250 250 #oSubPlot.grid(True, 'major', axis = 'none'); … … 278 278 self.setFontSize(6); 279 279 280 def renderGraph(self): # pylint: disable= R0914280 def renderGraph(self): # pylint: disable=too-many-locals 281 281 assert len(self._oData.aoSeries) == 1; 282 282 oSeries = self._oData.aoSeries[0]; … … 288 288 289 289 oFigure = self._createFigure(); 290 from mpl_toolkits.axes_grid.axislines import SubplotZero; # pylint: disable= E0401290 from mpl_toolkits.axes_grid.axislines import SubplotZero; # pylint: disable=import-error 291 291 oAxis = SubplotZero(oFigure, 111); 292 292 oFigure.add_subplot(oAxis); -
trunk/src/VBox/ValidationKit/testmanager/webui/wuimain.py
r76553 r79087 717 717 # 718 718 719 def _actionGroupedResultsListing( #pylint: disable= R0914719 def _actionGroupedResultsListing( #pylint: disable=too-many-locals 720 720 self, 721 721 enmResultsGroupingType, -
trunk/src/VBox/ValidationKit/testmanager/webui/wuireport.py
r76553 r79087 416 416 oTable.addRow(oPeriod.sDesc, aiValues, asValues); 417 417 418 if True: # pylint: disable= W0125418 if True: # pylint: disable=using-constant-test 419 419 aiValues = []; 420 420 asValues = []; -
trunk/src/VBox/ValidationKit/testmanager/webui/wuitestresult.py
r76553 r79087 154 154 155 155 def _recursivelyGenerateEvents(self, oTestResult, sParentName, sLineage, iRow, 156 iFailure, oTestSet, iDepth): # pylint: disable= R0914156 iFailure, oTestSet, iDepth): # pylint: disable=too-many-locals 157 157 """ 158 158 Recursively generate event table rows for the result set. … … 442 442 443 443 444 def showTestCaseResultDetails(self, # pylint: disable= R0914,R0915444 def showTestCaseResultDetails(self, # pylint: disable=too-many-locals,too-many-statements 445 445 oTestResultTree, 446 446 oTestSet, -
trunk/src/VBox/ValidationKit/tests/additions/tdAddBasic1.py
r79067 r79087 53 53 54 54 55 class tdAddBasic1(vbox.TestDriver): # pylint: disable= R090255 class tdAddBasic1(vbox.TestDriver): # pylint: disable=too-many-instance-attributes 56 56 """ 57 57 Additions Basics #1. … … 84 84 return rc; 85 85 86 def parseOption(self, asArgs, iArg): # pylint: disable=R0912,R091586 def parseOption(self, asArgs, iArg): # pylint: disable=too-many-branches,too-many-statements 87 87 if asArgs[iArg] == '--tests': 88 88 iArg += 1; -
trunk/src/VBox/ValidationKit/tests/additions/tdAddGuestCtrl.py
r79071 r79087 1 1 #!/usr/bin/env python 2 2 # -*- coding: utf-8 -*- 3 # pylint: disable= C03023 # pylint: disable=too-many-lines 4 4 5 5 """ … … 31 31 32 32 # Disable bitching about too many arguments per function. 33 # pylint: disable=R0913 34 35 # Disable bitching about semicolons at the end of lines. 36 # pylint: disable=W0301 33 # pylint: disable=too-many-arguments 37 34 38 35 ## @todo Convert map() usage to a cleaner alternative Python now offers. 39 # pylint: disable= W014136 # pylint: disable=bad-builtin 40 37 41 38 ## @todo Convert the context/test classes into named tuples. Not in the mood right now, so 42 39 # disabling it. 43 # pylint: disable= R090340 # pylint: disable=too-few-public-methods 44 41 45 42 # Standard Python imports. … … 48 45 import os 49 46 import random 50 import string # pylint: disable= W040247 import string # pylint: disable=deprecated-module 51 48 import struct 52 49 import sys … … 70 67 # Python 3 hacks: 71 68 if sys.version_info[0] >= 3: 72 long = int # pylint: disable= W0622,C010369 long = int # pylint: disable=redefined-builtin,invalid-name 73 70 74 71 … … 89 86 as generic as possible. 90 87 """ 91 def __init__(self, oSession, oTxsSession, oTestVm): # pylint: disable= W061388 def __init__(self, oSession, oTxsSession, oTestVm): # pylint: disable=unused-argument 92 89 ## The desired Main API result. 93 90 self.fRc = False; … … 188 185 # therefore return WaitFlagNotSupported. 189 186 # 190 if waitResult != vboxcon.GuestSessionWaitResult_Start \ 191 and waitResult != vboxcon.GuestSessionWaitResult_WaitFlagNotSupported: 187 if waitResult not in (vboxcon.GuestSessionWaitResult_Start, vboxcon.GuestSessionWaitResult_WaitFlagNotSupported): 192 188 # Just log, don't assume an error here (will be done in the main loop then). 193 189 reporter.log('Session did not start successfully, returned wait result: %d' \ … … 955 951 self.asRsrcs = ['5.3/guestctrl/50mb_rnd.dat', ]; 956 952 957 def parseOption(self, asArgs, iArg): # pylint: disable= R0912,R0915953 def parseOption(self, asArgs, iArg): # pylint: disable=too-many-branches,too-many-statements 958 954 if asArgs[iArg] == '--add-guest-ctrl-tests': 959 955 iArg += 1; … … 1197 1193 return fRc; 1198 1194 1199 def gctrlReadDir(self, oTest, oRes, oGuestSession, subDir = ''): # pylint: disable= R09141195 def gctrlReadDir(self, oTest, oRes, oGuestSession, subDir = ''): # pylint: disable=too-many-locals 1200 1196 """ 1201 1197 Helper function to read a guest directory specified in … … 1281 1277 map(hex, map(ord, oRes.sBuf)), len(oRes.sBuf))); 1282 1278 return False; 1283 else: 1284 reporter.log2('Test #%d passed: Buffers match (%d bytes)' % (i, len(oRes.sBuf))); 1279 reporter.log2('Test #%d passed: Buffers match (%d bytes)' % (i, len(oRes.sBuf))); 1285 1280 elif oRes.sBuf is not None \ 1286 1281 and oRes.sBuf: … … 1338 1333 try: 1339 1334 # Try stdout. 1340 if waitResult == vboxcon.ProcessWaitResult_StdOut \ 1341 or waitResult == vboxcon.ProcessWaitResult_WaitFlagNotSupported: 1335 if waitResult in (vboxcon.ProcessWaitResult_StdOut, vboxcon.ProcessWaitResult_WaitFlagNotSupported): 1342 1336 reporter.log2('Reading stdout ...'); 1343 1337 abBuf = curProc.Read(1, 64 * 1024, oTest.timeoutMS); … … 1347 1341 oTest.sBuf = abBuf; # Appending does *not* work atm, so just assign it. No time now. 1348 1342 # Try stderr. 1349 if waitResult == vboxcon.ProcessWaitResult_StdErr \ 1350 or waitResult == vboxcon.ProcessWaitResult_WaitFlagNotSupported: 1343 if waitResult in (vboxcon.ProcessWaitResult_StdErr, vboxcon.ProcessWaitResult_WaitFlagNotSupported): 1351 1344 reporter.log2('Reading stderr ...'); 1352 1345 abBuf = curProc.Read(2, 64 * 1024, oTest.timeoutMS); … … 1356 1349 oTest.sBuf = abBuf; # Appending does *not* work atm, so just assign it. No time now. 1357 1350 # Use stdin. 1358 if waitResult == vboxcon.ProcessWaitResult_StdIn \ 1359 or waitResult == vboxcon.ProcessWaitResult_WaitFlagNotSupported: 1351 if waitResult in (vboxcon.ProcessWaitResult_StdIn, vboxcon.ProcessWaitResult_WaitFlagNotSupported): 1360 1352 pass; #reporter.log2('Process (PID %d) needs stdin data' % (curProc.pid,)); 1361 1353 # Termination or error? 1362 if waitResult == vboxcon.ProcessWaitResult_Terminate \1363 or waitResult == vboxcon.ProcessWaitResult_Error \1364 or waitResult == vboxcon.ProcessWaitResult_Timeout:1354 if waitResult in (vboxcon.ProcessWaitResult_Terminate, 1355 vboxcon.ProcessWaitResult_Error, 1356 vboxcon.ProcessWaitResult_Timeout,): 1365 1357 reporter.log2('Process (PID %d) reported terminate/error/timeout: %d, status: %d' \ 1366 1358 % (curProc.PID, waitResult, curProc.status)); … … 1385 1377 return fRc; 1386 1378 1387 def testGuestCtrlSessionEnvironment(self, oSession, oTxsSession, oTestVm): # pylint: disable= R09141379 def testGuestCtrlSessionEnvironment(self, oSession, oTxsSession, oTestVm): # pylint: disable=too-many-locals 1388 1380 """ 1389 1381 Tests the guest session environment changes. … … 1487 1479 return tdTestSessionEx.executeListTestSessions(aoTests, self.oTstDrv, oSession, oTxsSession, oTestVm, 'SessionEnv'); 1488 1480 1489 def testGuestCtrlSession(self, oSession, oTxsSession, oTestVm): # pylint: disable= R09141481 def testGuestCtrlSession(self, oSession, oTxsSession, oTestVm): # pylint: disable=too-many-locals 1490 1482 """ 1491 1483 Tests the guest session handling. … … 1591 1583 break; 1592 1584 curSessionCount = multiSession[i].getSessionCount(self.oTstDrv.oVBoxMgr); 1593 if curSessionCount is not1:1585 if curSessionCount != 1: 1594 1586 reporter.error('Final MultiSession count #2 must be 1, got %d' % (curSessionCount,)); 1595 1587 fRc = False; … … 1612 1604 multiSession[iLastSession].closeSession(); 1613 1605 curSessionCount = multiSession[i].getSessionCount(self.oTstDrv.oVBoxMgr); 1614 if curSessionCount is not0:1606 if curSessionCount != 0: 1615 1607 reporter.error('Final MultiSession count #3 must be 0, got %d' % (curSessionCount,)); 1616 1608 fRc = False; … … 1623 1615 return (fRc, oTxsSession); 1624 1616 1625 def testGuestCtrlSessionFileRefs(self, oSession, oTxsSession, oTestVm): # pylint: disable= R09141617 def testGuestCtrlSessionFileRefs(self, oSession, oTxsSession, oTestVm): # pylint: disable=too-many-locals 1626 1618 """ 1627 1619 Tests the guest session file reference handling. … … 1650 1642 # therefore return WaitFlagNotSupported. 1651 1643 # 1652 if waitResult != vboxcon.GuestSessionWaitResult_Start \ 1653 and waitResult != vboxcon.GuestSessionWaitResult_WaitFlagNotSupported: 1644 if waitResult not in (vboxcon.GuestSessionWaitResult_Start, vboxcon.GuestSessionWaitResult_WaitFlagNotSupported): 1654 1645 # Just log, don't assume an error here (will be done in the main loop then). 1655 1646 reporter.log('Session did not start successfully, returned wait result: %d' \ … … 1760 1751 # return (fRc, oTxsSession); 1761 1752 1762 def testGuestCtrlSessionProcRefs(self, oSession, oTxsSession, oTestVm): # pylint: disable= R09141753 def testGuestCtrlSessionProcRefs(self, oSession, oTxsSession, oTestVm): # pylint: disable=too-many-locals 1763 1754 """ 1764 1755 Tests the guest session process reference handling. … … 1788 1779 # therefore return WaitFlagNotSupported. 1789 1780 # 1790 if waitResult != vboxcon.GuestSessionWaitResult_Start \ 1791 and waitResult != vboxcon.GuestSessionWaitResult_WaitFlagNotSupported: 1781 if waitResult not in (vboxcon.GuestSessionWaitResult_Start, vboxcon.GuestSessionWaitResult_WaitFlagNotSupported): 1792 1782 # Just log, don't assume an error here (will be done in the main loop then). 1793 1783 reporter.log('Session did not start successfully, returned wait result: %d' \ … … 1917 1907 return (fRc, oTxsSession); 1918 1908 1919 def testGuestCtrlExec(self, oSession, oTxsSession, oTestVm): # pylint: disable= R0914,R09151909 def testGuestCtrlExec(self, oSession, oTxsSession, oTestVm): # pylint: disable=too-many-locals,too-many-statements 1920 1910 """ 1921 1911 Tests the basic execution feature. … … 2084 2074 aSessions = self.oTstDrv.oVBoxMgr.getArray(oSession.o.console.guest, 'sessions'); 2085 2075 cSessions = len(aSessions); 2086 if cSessions is not0:2076 if cSessions != 0: 2087 2077 reporter.error('Found %d stale session(s), expected 0:' % (cSessions,)); 2088 2078 for (i, aSession) in enumerate(aSessions): … … 2106 2096 fWaitFor = [ vboxcon.GuestSessionWaitForFlag_Start ]; 2107 2097 waitResult = curGuestSession.waitForArray(fWaitFor, 30 * 1000); 2108 if waitResult != vboxcon.GuestSessionWaitResult_Start \ 2109 and waitResult != vboxcon.GuestSessionWaitResult_WaitFlagNotSupported: 2098 if waitResult not in (vboxcon.GuestSessionWaitResult_Start, vboxcon.GuestSessionWaitResult_WaitFlagNotSupported): 2110 2099 reporter.error('Session did not start successfully, returned wait result: %d' \ 2111 2100 % (waitResult)); … … 2142 2131 if fRc is True: 2143 2132 cSessions = len(self.oTstDrv.oVBoxMgr.getArray(oSession.o.console.guest, 'sessions')); 2144 if cSessions is not0:2133 if cSessions != 0: 2145 2134 reporter.error('Found %d stale session(s), expected 0' % (cSessions,)); 2146 2135 fRc = False; … … 2164 2153 % (waitResult, oGuestProcess.status)); 2165 2154 2166 def testGuestCtrlSessionReboot(self, oSession, oTxsSession, oTestVm): # pylint: disable= R09142155 def testGuestCtrlSessionReboot(self, oSession, oTxsSession, oTestVm): # pylint: disable=too-many-locals 2167 2156 """ 2168 2157 Tests guest object notifications when a guest gets rebooted / shutdown. … … 2191 2180 fWaitFor = [ vboxcon.GuestSessionWaitForFlag_Start ]; 2192 2181 waitResult = oGuestSession.waitForArray(fWaitFor, 30 * 1000); 2193 if waitResult != vboxcon.GuestSessionWaitResult_Start \ 2194 and waitResult != vboxcon.GuestSessionWaitResult_WaitFlagNotSupported: 2182 if waitResult not in (vboxcon.GuestSessionWaitResult_Start, vboxcon.GuestSessionWaitResult_WaitFlagNotSupported): 2195 2183 reporter.error('Session did not start successfully, returned wait result: %d' \ 2196 2184 % (waitResult)); … … 2495 2483 return (fRc, oTxsSession); 2496 2484 2497 def testGuestCtrlDirCreateTemp(self, oSession, oTxsSession, oTestVm): # pylint: disable= R09142485 def testGuestCtrlDirCreateTemp(self, oSession, oTxsSession, oTestVm): # pylint: disable=too-many-locals 2498 2486 """ 2499 2487 Tests creation of temporary directories. … … 2643 2631 return (fRc, oTxsSession); 2644 2632 2645 def testGuestCtrlDirRead(self, oSession, oTxsSession, oTestVm): # pylint: disable= R09142633 def testGuestCtrlDirRead(self, oSession, oTxsSession, oTestVm): # pylint: disable=too-many-locals 2646 2634 """ 2647 2635 Tests opening and reading (enumerating) guest directories. … … 2795 2783 return (fRc, oTxsSession); 2796 2784 2797 def testGuestCtrlFileStat(self, oSession, oTxsSession, oTestVm): # pylint: disable= R09142785 def testGuestCtrlFileStat(self, oSession, oTxsSession, oTestVm): # pylint: disable=too-many-locals 2798 2786 """ 2799 2787 Tests querying file information through stat. … … 2880 2868 return tdTestSessionEx.executeListTestSessions(aoTests, self.oTstDrv, oSession, oTxsSession, oTestVm, 'FsStat'); 2881 2869 2882 def testGuestCtrlFileRead(self, oSession, oTxsSession, oTestVm): # pylint: disable= R09142870 def testGuestCtrlFileRead(self, oSession, oTxsSession, oTestVm): # pylint: disable=too-many-locals 2883 2871 """ 2884 2872 Tests reading from guest files. … … 3033 3021 return (fRc, oTxsSession); 3034 3022 3035 def testGuestCtrlFileWrite(self, oSession, oTxsSession, oTestVm): # pylint: disable= R09143023 def testGuestCtrlFileWrite(self, oSession, oTxsSession, oTestVm): # pylint: disable=too-many-locals 3036 3024 """ 3037 3025 Tests writing to guest files. … … 3325 3313 return (fRc, oTxsSession); 3326 3314 3327 def testGuestCtrlCopyFrom(self, oSession, oTxsSession, oTestVm): # pylint: disable= R09143315 def testGuestCtrlCopyFrom(self, oSession, oTxsSession, oTestVm): # pylint: disable=too-many-locals 3328 3316 """ 3329 3317 Tests copying files from guest to the host. … … 3490 3478 return (fRc, oTxsSession); 3491 3479 3492 def testGuestCtrlUpdateAdditions(self, oSession, oTxsSession, oTestVm): # pylint: disable= R09143480 def testGuestCtrlUpdateAdditions(self, oSession, oTxsSession, oTestVm): # pylint: disable=too-many-locals 3493 3481 """ 3494 3482 Tests updating the Guest Additions inside the guest. … … 3601 3589 3602 3590 3603 class tdAddGuestCtrl(vbox.TestDriver): # pylint: disable= R0902,R09043591 class tdAddGuestCtrl(vbox.TestDriver): # pylint: disable=too-many-instance-attributes,too-many-public-methods 3604 3592 """ 3605 3593 Guest control using VBoxService on the guest. … … 3627 3615 return rc; 3628 3616 3629 def parseOption(self, asArgs, iArg): # pylint: disable= R0912,R09153617 def parseOption(self, asArgs, iArg): # pylint: disable=too-many-branches,too-many-statements 3630 3618 """ 3631 3619 Parses the testdriver arguments from the command line. … … 3653 3641 # Test execution helpers. 3654 3642 # 3655 def testOneCfg(self, oVM, oTestVm): # pylint: disable= R09153643 def testOneCfg(self, oVM, oTestVm): # pylint: disable=too-many-statements 3656 3644 """ 3657 3645 Runs the specified VM thru the tests. … … 3701 3689 based from a timeout value and the start time (both in ms). 3702 3690 """ 3703 if msTimeout is0:3691 if msTimeout == 0: 3704 3692 return 0xFFFFFFFE; # Wait forever. 3705 3693 msElapsed = base.timestampMilli() - msStart; … … 3708 3696 return msTimeout - msElapsed; 3709 3697 3710 def testGuestCtrlManual(self, oSession, oTxsSession, oTestVm): # pylint: disable= R0914,R0915,W0613,W06123698 def testGuestCtrlManual(self, oSession, oTxsSession, oTestVm): # pylint: disable=too-many-locals,too-many-statements,unused-argument,unused-variable 3711 3699 """ 3712 3700 For manually testing certain bits. -
trunk/src/VBox/ValidationKit/tests/audio/tdGuestHostTimings.py
r76553 r79087 50 50 from testdriver import vboxtestvms 51 51 52 class tdGuestHostTimings(vbox.TestDriver): # pylint: disable= R090252 class tdGuestHostTimings(vbox.TestDriver): # pylint: disable=too-many-instance-attributes 53 53 54 54 def __init__(self): … … 75 75 return rc; 76 76 77 def parseOption(self, asArgs, iArg): # pylint: disable= R0912,R091577 def parseOption(self, asArgs, iArg): # pylint: disable=too-many-branches,too-many-statements 78 78 if asArgs[iArg] == '--runningvmname': 79 79 iArg += 1 -
trunk/src/VBox/ValidationKit/tests/autostart/tdAutostart1.py
r76553 r79087 185 185 return fRc; 186 186 187 # pylint: disable= R0913187 # pylint: disable=too-many-arguments 188 188 189 189 def runProgAsUser(self, oTxsSession, sTestName, cMsTimeout, sExecName, sAsUser, asArgs = (), … … 199 199 return fRc; 200 200 201 # pylint: enable= R0913201 # pylint: enable=too-many-arguments 202 202 203 203 def createTestVM(self, oSession, oTxsSession, sUser, sVmName): … … 355 355 return fRc; 356 356 357 # pylint: disable= R0913357 # pylint: disable=too-many-arguments 358 358 359 359 def runProgAsUser(self, oTxsSession, sTestName, cMsTimeout, sExecName, sAsUser, asArgs = (), … … 369 369 return fRc; 370 370 371 # pylint: enable= R0913371 # pylint: enable=too-many-arguments 372 372 373 373 def createTestVM(self, oSession, oTxsSession, sUser, sVmName): … … 446 446 return False; 447 447 448 class tdAutostart(vbox.TestDriver): # pylint: disable= R0902448 class tdAutostart(vbox.TestDriver): # pylint: disable=too-many-instance-attributes 449 449 """ 450 450 Autostart testcase. … … 482 482 return rc; 483 483 484 def parseOption(self, asArgs, iArg): # pylint: disable= R0912,R0915484 def parseOption(self, asArgs, iArg): # pylint: disable=too-many-branches,too-many-statements 485 485 if asArgs[iArg] == '--test-build-dir': 486 486 iArg += 1; … … 569 569 reporter.testStart('Autostart ' + sVmName); 570 570 571 oGuestOsHlp = None ;# type: tdAutostartOs571 oGuestOsHlp = None # type: tdAutostartOs 572 572 if sVmName == self.ksOsLinux: 573 573 oGuestOsHlp = tdAutostartOsLinux(self, self.sTestBuildDir); -
trunk/src/VBox/ValidationKit/tests/installation/tdGuestOsInstTest1.py
r78824 r79087 223 223 oSet = vboxtestvms.TestVmSet(self.oTestVmManager, fIgnoreSkippedVm = True); 224 224 oSet.aoTestVms.extend([ 225 # pylint: disable= C0301225 # pylint: disable=line-too-long 226 226 InstallTestVm(oSet, 'tst-fedora4', 'Fedora', 'fedora4-txs.iso', InstallTestVm.ksIdeController, 8, InstallTestVm.kf32Bit), 227 227 InstallTestVm(oSet, 'tst-fedora5', 'Fedora', 'fedora5-txs.iso', InstallTestVm.ksSataController, 8, InstallTestVm.kf32Bit | InstallTestVm.kfReqPae | InstallTestVm.kfReqIoApicSmp), … … 261 261 InstallTestVm(oSet, 'tst-w10-32', 'Windows10', 'win10-x86-txs.iso', InstallTestVm.ksSataController, 25, InstallTestVm.kf32Bit | InstallTestVm.kfReqPae), 262 262 InstallTestVm(oSet, 'tst-w10-64', 'Windows10_64', 'win10-x64-txs.iso', InstallTestVm.ksSataController, 25, InstallTestVm.kf64Bit), 263 # pylint: enable= C0301263 # pylint: enable=line-too-long 264 264 ]); 265 265 self.oTestVmSet = oSet; -
trunk/src/VBox/ValidationKit/tests/network/tdNetBenchmark1.py
r76553 r79087 49 49 50 50 51 class tdNetBenchmark1(vbox.TestDriver): # pylint: disable= R090251 class tdNetBenchmark1(vbox.TestDriver): # pylint: disable=too-many-instance-attributes 52 52 """ 53 53 Networking benchmark #1. … … 130 130 return rc; 131 131 132 def parseOption(self, asArgs, iArg): # pylint: disable= R0912,R0915132 def parseOption(self, asArgs, iArg): # pylint: disable=too-many-branches,too-many-statements 133 133 if asArgs[iArg] == '--remote-host': 134 134 iArg += 1; -
trunk/src/VBox/ValidationKit/tests/storage/remoteexecutor.py
r76553 r79087 162 162 oStdIn = StdInOutBuffer(sInput); 163 163 else: 164 oStdIn = '/dev/null'; # pylint: disable= R0204164 oStdIn = '/dev/null'; # pylint: disable=redefined-variable-type 165 165 fRc = self.oTxsSession.syncExecEx(sExec, (sExec,) + asArgs, 166 166 oStdIn = oStdIn, oStdOut = oStdOut, -
trunk/src/VBox/ValidationKit/tests/storage/storagecfg.py
r76553 r79087 428 428 oStorOs = StorageConfigOsSolaris(); 429 429 elif sTargetOs == 'linux': 430 oStorOs = StorageConfigOsLinux(); # pylint: disable= R0204430 oStorOs = StorageConfigOsLinux(); # pylint: disable=redefined-variable-type 431 431 else: 432 432 fRc = False; … … 450 450 451 451 # Destroy all volumes first. 452 for sMountPoint in self.dVols.keys(): # pylint: disable= C0201452 for sMountPoint in self.dVols.keys(): # pylint: disable=consider-iterating-dictionary 453 453 self.destroyVolume(sMountPoint); 454 454 455 455 # Destroy all pools. 456 for sPool in self.dPools.keys(): # pylint: disable= C0201456 for sPool in self.dPools.keys(): # pylint: disable=consider-iterating-dictionary 457 457 self.destroyStoragePool(sPool); 458 458 -
trunk/src/VBox/ValidationKit/tests/storage/tdStorageBenchmark1.py
r76553 r79087 36 36 import sys; 37 37 if sys.version_info[0] >= 3: 38 from io import StringIO as StringIO; # pylint: disable=import-error,no-name-in-module 38 from io import StringIO as StringIO; # pylint: disable=import-error,no-name-in-module,useless-import-alias 39 39 else: 40 from StringIO import StringIO as StringIO; # pylint: disable=import-error,no-name-in-module 40 from StringIO import StringIO as StringIO; # pylint: disable=import-error,no-name-in-module,useless-import-alias 41 41 42 42 # Only the main script needs to modify the path. … … 61 61 def _ControllerTypeToName(eControllerType): 62 62 """ Translate a controller type to a name. """ 63 if eControllerType == vboxcon.StorageControllerType_PIIX3 or eControllerType == vboxcon.StorageControllerType_PIIX4:63 if eControllerType in (vboxcon.StorageControllerType_PIIX3, eControllerType == vboxcon.StorageControllerType_PIIX4,): 64 64 sType = "IDE Controller"; 65 65 elif eControllerType == vboxcon.StorageControllerType_IntelAhci: … … 67 67 elif eControllerType == vboxcon.StorageControllerType_LsiLogicSas: 68 68 sType = "SAS Controller"; 69 elif eControllerType == vboxcon.StorageControllerType_LsiLogic or eControllerType == vboxcon.StorageControllerType_BusLogic:69 elif eControllerType in (vboxcon.StorageControllerType_LsiLogic, vboxcon.StorageControllerType_BusLogic,): 70 70 sType = "SCSI Controller"; 71 71 elif eControllerType == vboxcon.StorageControllerType_NVMe: … … 404 404 return asTestCfg; 405 405 406 class tdStorageBenchmark(vbox.TestDriver): # pylint: disable= R0902406 class tdStorageBenchmark(vbox.TestDriver): # pylint: disable=too-many-instance-attributes 407 407 """ 408 408 Storage benchmark. … … 579 579 return rc; 580 580 581 def parseOption(self, asArgs, iArg): # pylint: disable= R0912,R0915581 def parseOption(self, asArgs, iArg): # pylint: disable=too-many-branches,too-many-statements 582 582 if asArgs[iArg] == '--virt-modes': 583 583 iArg += 1; … … 944 944 oTst = IozoneTest(oExecutor, dTestSet); 945 945 elif sBenchmark == 'fio': 946 oTst = FioTest(oExecutor, dTestSet); # pylint: disable= R0204946 oTst = FioTest(oExecutor, dTestSet); # pylint: disable=redefined-variable-type 947 947 948 948 if oTst is not None: … … 1045 1045 return (None, None); 1046 1046 1047 def testOneCfg(self, sVmName, eStorageController, sHostIoCache, sDiskFormat, # pylint: disable= R0913,R0914,R09151047 def testOneCfg(self, sVmName, eStorageController, sHostIoCache, sDiskFormat, # pylint: disable=too-many-arguments,too-many-locals,too-many-statements 1048 1048 sDiskVariant, sDiskPath, cCpus, sIoTest, sVirtMode, sTestSet): 1049 1049 """ … … 1109 1109 1110 1110 iDevice = 0; 1111 if eStorageController == vboxcon.StorageControllerType_PIIX3 or \ 1112 eStorageController == vboxcon.StorageControllerType_PIIX4: 1111 if eStorageController in (vboxcon.StorageControllerType_PIIX3, vboxcon.StorageControllerType_PIIX4,): 1113 1112 iDevice = 1; # Master is for the OS. 1114 1113 … … 1141 1140 1142 1141 iLun = 0; 1143 if eStorageController == vboxcon.StorageControllerType_PIIX3 or \ 1144 eStorageController == vboxcon.StorageControllerType_PIIX4: 1142 if eStorageController in (vboxcon.StorageControllerType_PIIX3, vboxcon.StorageControllerType_PIIX4,): 1145 1143 iLun = 1 1146 1144 sDrv, fDrvScsi = self.getStorageDriverFromEnum(eStorageController, True); -
trunk/src/VBox/ValidationKit/tests/storage/tdStorageSnapshotMerging1.py
r79022 r79087 79 79 80 80 81 class tdStorageSnapshot(vbox.TestDriver): # pylint: disable= R090281 class tdStorageSnapshot(vbox.TestDriver): # pylint: disable=too-many-instance-attributes 82 82 """ 83 83 Storage benchmark. … … 109 109 return rc; 110 110 111 def parseOption(self, asArgs, iArg): # pylint: disable= R0912,R0915111 def parseOption(self, asArgs, iArg): # pylint: disable=too-many-branches,too-many-statements 112 112 if asArgs[iArg] == '--storage-ctrls': 113 113 iArg += 1; -
trunk/src/VBox/ValidationKit/tests/storage/tdStorageStress1.py
r76553 r79087 60 60 return sType; 61 61 62 class tdStorageStress(vbox.TestDriver): # pylint: disable= R090262 class tdStorageStress(vbox.TestDriver): # pylint: disable=too-many-instance-attributes 63 63 """ 64 64 Storage testcase. … … 125 125 return rc; 126 126 127 def parseOption(self, asArgs, iArg): # pylint: disable= R0912,R0915127 def parseOption(self, asArgs, iArg): # pylint: disable=too-many-branches,too-many-statements 128 128 if asArgs[iArg] == '--virt-modes': 129 129 iArg += 1; … … 326 326 return fRc; 327 327 328 # pylint: disable= R0913328 # pylint: disable=too-many-arguments 329 329 330 330 def test1OneCfg(self, sVmName, eStorageController, sDiskFormat, sDiskPath1, sDiskPath2, \ -
trunk/src/VBox/ValidationKit/tests/unittests/tdUnitTest1.py
r76553 r79087 99 99 'testcase/tstX86-1': '', # Fails on win.x86. 100 100 'tscpasswd': '', # ?? 101 'tstVMREQ': '', # ?? Same as darwin.x86?101 'tstVMREQ': '', # ?? Same as darwin.x86? 102 102 }, 103 103 'win.x86': { … … 505 505 return False; 506 506 reporter.log('Exit code [sudo]: %s (%s)' % (iRc, asArgs)); 507 return iRc is0;507 return iRc == 0; 508 508 509 509 def _hardenedMkDir(self, sPath): … … 565 565 return True; 566 566 567 def _executeTestCase(self, sName, sFullPath, sTestCaseSubDir, oDevNull): # pylint: disable= R0914567 def _executeTestCase(self, sName, sFullPath, sTestCaseSubDir, oDevNull): # pylint: disable=too-many-locals 568 568 """ 569 569 Executes a test case. -
trunk/src/VBox/ValidationKit/tests/usb/tdUsb1.py
r76553 r79087 56 56 57 57 58 class tdUsbBenchmark(vbox.TestDriver): # pylint: disable= R090258 class tdUsbBenchmark(vbox.TestDriver): # pylint: disable=too-many-instance-attributes 59 59 """ 60 60 USB benchmark. … … 154 154 return rc; 155 155 156 def parseOption(self, asArgs, iArg): # pylint: disable= R0912,R0915156 def parseOption(self, asArgs, iArg): # pylint: disable=too-many-branches,too-many-statements 157 157 if asArgs[iArg] == '--virt-modes': 158 158 iArg += 1; … … 423 423 return fRc; 424 424 425 def testUsbReattach(self, oSession, oTxsSession, sUsbCtrl, sSpeed, sCaptureFile = None): # pylint: disable= W0613425 def testUsbReattach(self, oSession, oTxsSession, sUsbCtrl, sSpeed, sCaptureFile = None): # pylint: disable=unused-argument 426 426 """ 427 427 Tests that rapid connect/disconnect cycles work. -
trunk/src/VBox/ValidationKit/tests/usb/tst-utsgadget.py
r76553 r79087 69 69 return 'FAILED'; 70 70 71 def main(asArgs): # pylint: disable= C0111,R0914,R091571 def main(asArgs): # pylint: disable=missing-docstring,too-many-locals,too-many-statements 72 72 cMsTimeout = long(30*1000); 73 73 sAddress = 'localhost'; -
trunk/src/VBox/ValidationKit/tests/usb/usbgadget.py
r76553 r79087 1 1 # -*- coding: utf-8 -*- 2 2 # $Id$ 3 # pylint: disable= C03023 # pylint: disable=too-many-lines 4 4 5 5 """ … … 193 193 abArray = array.array('B', (0, )); 194 194 cb = cb - 1; 195 for i in range(cb): # pylint: disable= W0612195 for i in range(cb): # pylint: disable=unused-variable 196 196 abArray.append(0); 197 197 return abArray; … … 985 985 if oXcpt[0] == errno.EWOULDBLOCK: 986 986 return True; 987 if utils.getHostOs == 'win' and oXcpt[0] == errno.WSAEWOULDBLOCK: # pylint: disable= E1101987 if utils.getHostOs == 'win' and oXcpt[0] == errno.WSAEWOULDBLOCK: # pylint: disable=no-member 988 988 return True; 989 989 except: pass; … … 1123 1123 oWakeupW = None; 1124 1124 if hasattr(socket, 'socketpair'): 1125 try: (oWakeupR, oWakeupW) = socket.socketpair(); # pylint: disable= E11011125 try: (oWakeupR, oWakeupW) = socket.socketpair(); # pylint: disable=no-member 1126 1126 except: reporter.logXcpt('socket.socketpair() failed'); 1127 1127
Note:
See TracChangeset
for help on using the changeset viewer.