VirtualBox

Changeset 57289 in vbox for trunk/src/VBox/ValidationKit


Ignore:
Timestamp:
Aug 12, 2015 12:15:31 PM (10 years ago)
Author:
vboxsync
svn:sync-xref-src-repo-rev:
102048
Message:

validationkit/tests: new pylint complains about continuation indenting, started cleaning it up...

Location:
trunk/src/VBox/ValidationKit/tests
Files:
5 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/ValidationKit/tests/additions/tdAddGuestCtrl.py

    r56755 r57289  
    15111511            # Check basic operations.
    15121512            tdTestSessionEx([ # Initial environment is empty.
    1513                               tdStepSessionCheckEnv(),
    1514                               # Check clearing empty env.
    1515                               tdStepSessionClearEnv(),
    1516                               tdStepSessionCheckEnv(),
    1517                               # Check set.
    1518                               tdStepSessionSetEnv('FOO', 'BAR'),
    1519                               tdStepSessionCheckEnv(['FOO=BAR',]),
    1520                               tdStepRequireMinimumApiVer(5.0), # 4.3 can't cope with the remainder.
    1521                               tdStepSessionClearEnv(),
    1522                               tdStepSessionCheckEnv(),
    1523                               # Check unset.
    1524                               tdStepSessionUnsetEnv('BAR'),
    1525                               tdStepSessionCheckEnv(['BAR']),
    1526                               tdStepSessionClearEnv(),
    1527                               tdStepSessionCheckEnv(),
    1528                               # Set + unset.
    1529                               tdStepSessionSetEnv('FOO', 'BAR'),
    1530                               tdStepSessionCheckEnv(['FOO=BAR',]),
    1531                               tdStepSessionUnsetEnv('FOO'),
    1532                               tdStepSessionCheckEnv(['FOO']),
    1533                               # Bulk environment changes (via attrib) (shall replace existing 'FOO').
    1534                               tdStepSessionBulkEnv( ['PATH=/bin:/usr/bin', 'TMPDIR=/var/tmp', 'USER=root']),
    1535                               tdStepSessionCheckEnv(['PATH=/bin:/usr/bin', 'TMPDIR=/var/tmp', 'USER=root']),
    1536                               ]),
     1513                tdStepSessionCheckEnv(),
     1514                # Check clearing empty env.
     1515                tdStepSessionClearEnv(),
     1516                tdStepSessionCheckEnv(),
     1517                # Check set.
     1518                tdStepSessionSetEnv('FOO', 'BAR'),
     1519                tdStepSessionCheckEnv(['FOO=BAR',]),
     1520                tdStepRequireMinimumApiVer(5.0), # 4.3 can't cope with the remainder.
     1521                tdStepSessionClearEnv(),
     1522                tdStepSessionCheckEnv(),
     1523                # Check unset.
     1524                tdStepSessionUnsetEnv('BAR'),
     1525                tdStepSessionCheckEnv(['BAR']),
     1526                tdStepSessionClearEnv(),
     1527                tdStepSessionCheckEnv(),
     1528                # Set + unset.
     1529                tdStepSessionSetEnv('FOO', 'BAR'),
     1530                tdStepSessionCheckEnv(['FOO=BAR',]),
     1531                tdStepSessionUnsetEnv('FOO'),
     1532                tdStepSessionCheckEnv(['FOO']),
     1533                # Bulk environment changes (via attrib) (shall replace existing 'FOO').
     1534                tdStepSessionBulkEnv( ['PATH=/bin:/usr/bin', 'TMPDIR=/var/tmp', 'USER=root']),
     1535                tdStepSessionCheckEnv(['PATH=/bin:/usr/bin', 'TMPDIR=/var/tmp', 'USER=root']),
     1536                ]),
    15371537            tdTestSessionEx([ # Check that setting the same value several times works.
    1538                               tdStepSessionSetEnv('FOO','BAR'),
    1539                               tdStepSessionCheckEnv([ 'FOO=BAR',]),
    1540                               tdStepSessionSetEnv('FOO','BAR2'),
    1541                               tdStepSessionCheckEnv([ 'FOO=BAR2',]),
    1542                               tdStepSessionSetEnv('FOO','BAR3'),
    1543                               tdStepSessionCheckEnv([ 'FOO=BAR3',]),
    1544                               tdStepRequireMinimumApiVer(5.0), # 4.3 can't cope with the remainder.
    1545                               # Add a little unsetting to the mix.
    1546                               tdStepSessionSetEnv('BAR', 'BEAR'),
    1547                               tdStepSessionCheckEnv([ 'FOO=BAR3', 'BAR=BEAR',]),
    1548                               tdStepSessionUnsetEnv('FOO'),
    1549                               tdStepSessionCheckEnv([ 'FOO', 'BAR=BEAR',]),
    1550                               tdStepSessionSetEnv('FOO','BAR4'),
    1551                               tdStepSessionCheckEnv([ 'FOO=BAR4', 'BAR=BEAR',]),
    1552                               # The environment is case sensitive.
    1553                               tdStepSessionSetEnv('foo','BAR5'),
    1554                               tdStepSessionCheckEnv([ 'FOO=BAR4', 'BAR=BEAR', 'foo=BAR5']),
    1555                               tdStepSessionUnsetEnv('foo'),
    1556                               tdStepSessionCheckEnv([ 'FOO=BAR4', 'BAR=BEAR', 'foo']),
    1557                               ]),
     1538                tdStepSessionSetEnv('FOO','BAR'),
     1539                tdStepSessionCheckEnv([ 'FOO=BAR',]),
     1540                tdStepSessionSetEnv('FOO','BAR2'),
     1541                tdStepSessionCheckEnv([ 'FOO=BAR2',]),
     1542                tdStepSessionSetEnv('FOO','BAR3'),
     1543                tdStepSessionCheckEnv([ 'FOO=BAR3',]),
     1544                tdStepRequireMinimumApiVer(5.0), # 4.3 can't cope with the remainder.
     1545                # Add a little unsetting to the mix.
     1546                tdStepSessionSetEnv('BAR', 'BEAR'),
     1547                tdStepSessionCheckEnv([ 'FOO=BAR3', 'BAR=BEAR',]),
     1548                tdStepSessionUnsetEnv('FOO'),
     1549                tdStepSessionCheckEnv([ 'FOO', 'BAR=BEAR',]),
     1550                tdStepSessionSetEnv('FOO','BAR4'),
     1551                tdStepSessionCheckEnv([ 'FOO=BAR4', 'BAR=BEAR',]),
     1552                # The environment is case sensitive.
     1553                tdStepSessionSetEnv('foo','BAR5'),
     1554                tdStepSessionCheckEnv([ 'FOO=BAR4', 'BAR=BEAR', 'foo=BAR5']),
     1555                tdStepSessionUnsetEnv('foo'),
     1556                tdStepSessionCheckEnv([ 'FOO=BAR4', 'BAR=BEAR', 'foo']),
     1557                ]),
    15581558            tdTestSessionEx([ # Bulk settings merges stuff, last entry standing.
    1559                               tdStepSessionBulkEnv(['FOO=bar', 'foo=bar', 'FOO=doofus', 'TMPDIR=/tmp', 'foo=bar2']),
    1560                               tdStepSessionCheckEnv(['FOO=doofus', 'TMPDIR=/tmp', 'foo=bar2']),
    1561                               tdStepRequireMinimumApiVer(5.0), # 4.3 is buggy!
    1562                               tdStepSessionBulkEnv(['2=1+1', 'FOO=doofus2', ]),
    1563                               tdStepSessionCheckEnv(['2=1+1', 'FOO=doofus2' ]),
    1564                               ]),
     1559                tdStepSessionBulkEnv(['FOO=bar', 'foo=bar', 'FOO=doofus', 'TMPDIR=/tmp', 'foo=bar2']),
     1560                tdStepSessionCheckEnv(['FOO=doofus', 'TMPDIR=/tmp', 'foo=bar2']),
     1561                tdStepRequireMinimumApiVer(5.0), # 4.3 is buggy!
     1562                tdStepSessionBulkEnv(['2=1+1', 'FOO=doofus2', ]),
     1563                tdStepSessionCheckEnv(['2=1+1', 'FOO=doofus2' ]),
     1564                ]),
    15651565            # Invalid variable names.
    1566             tdTestSessionEx([ tdStepSessionSetEnv('', 'FOO', vbox.ComError.E_INVALIDARG),
    1567                               tdStepSessionCheckEnv(),
    1568                               tdStepRequireMinimumApiVer(5.0), # 4.3 is too relaxed checking input!
    1569                               tdStepSessionSetEnv('=', '===', vbox.ComError.E_INVALIDARG),
    1570                               tdStepSessionCheckEnv(),
    1571                               tdStepSessionSetEnv('FOO=', 'BAR', vbox.ComError.E_INVALIDARG),
    1572                               tdStepSessionCheckEnv(),
    1573                               tdStepSessionSetEnv('=FOO', 'BAR', vbox.ComError.E_INVALIDARG),
    1574                               tdStepSessionCheckEnv(),
    1575                               tdStepRequireMinimumApiVer(5.0), # 4.3 is buggy and too relaxed!
    1576                               tdStepSessionBulkEnv(['', 'foo=bar'], vbox.ComError.E_INVALIDARG),
    1577                               tdStepSessionCheckEnv(),
    1578                               tdStepSessionBulkEnv(['=', 'foo=bar'], vbox.ComError.E_INVALIDARG),
    1579                               tdStepSessionCheckEnv(),
    1580                               tdStepSessionBulkEnv(['=FOO', 'foo=bar'], vbox.ComError.E_INVALIDARG),
    1581                               tdStepSessionCheckEnv(),
    1582                               ]),
     1566            tdTestSessionEx([
     1567                tdStepSessionSetEnv('', 'FOO', vbox.ComError.E_INVALIDARG),
     1568                tdStepSessionCheckEnv(),
     1569                tdStepRequireMinimumApiVer(5.0), # 4.3 is too relaxed checking input!
     1570                tdStepSessionSetEnv('=', '===', vbox.ComError.E_INVALIDARG),
     1571                tdStepSessionCheckEnv(),
     1572                tdStepSessionSetEnv('FOO=', 'BAR', vbox.ComError.E_INVALIDARG),
     1573                tdStepSessionCheckEnv(),
     1574                tdStepSessionSetEnv('=FOO', 'BAR', vbox.ComError.E_INVALIDARG),
     1575                tdStepSessionCheckEnv(),
     1576                tdStepRequireMinimumApiVer(5.0), # 4.3 is buggy and too relaxed!
     1577                tdStepSessionBulkEnv(['', 'foo=bar'], vbox.ComError.E_INVALIDARG),
     1578                tdStepSessionCheckEnv(),
     1579                tdStepSessionBulkEnv(['=', 'foo=bar'], vbox.ComError.E_INVALIDARG),
     1580                tdStepSessionCheckEnv(),
     1581                tdStepSessionBulkEnv(['=FOO', 'foo=bar'], vbox.ComError.E_INVALIDARG),
     1582                tdStepSessionCheckEnv(),
     1583                ]),
    15831584            # A bit more weird keys/values.
    15841585            tdTestSessionEx([ tdStepSessionSetEnv('$$$', ''),
     
    15861587            tdTestSessionEx([ tdStepSessionSetEnv('$$$', '%%%'),
    15871588                              tdStepSessionCheckEnv([ '$$$=%%%',]),
    1588                               ]),
     1589                            ]),
    15891590            tdTestSessionEx([ tdStepRequireMinimumApiVer(5.0), # 4.3 is buggy!
    15901591                              tdStepSessionSetEnv(u'ß$%ß&', ''),
    15911592                              tdStepSessionCheckEnv([ u'ß$%ß&=',]),
    1592                               ]),
     1593                            ]),
    15931594            # Misc stuff.
    15941595            tdTestSessionEx([ tdStepSessionSetEnv('FOO', ''),
    15951596                              tdStepSessionCheckEnv(['FOO=',]),
    1596                               ]),
     1597                            ]),
    15971598            tdTestSessionEx([ tdStepSessionSetEnv('FOO', 'BAR'),
    15981599                              tdStepSessionCheckEnv(['FOO=BAR',])
    1599                               ],),
     1600                            ],),
    16001601            tdTestSessionEx([ tdStepSessionSetEnv('FOO', 'BAR'),
    16011602                              tdStepSessionSetEnv('BAR', 'BAZ'),
    16021603                              tdStepSessionCheckEnv([ 'FOO=BAR', 'BAR=BAZ',]),
    1603                               ]),
     1604                            ]),
    16041605        ];
    16051606        return tdTestSessionEx.executeListTestSessions(aoTests, self.oTstDrv, oSession, oTxsSession, oTestVm, 'SessionEnv');
     
    25222523                [ tdTestDirCreate(sUser = sUser, sPassword = sPassword,
    25232524                                  sDirectory = os.path.join(sScratch,
    2524                                   "".join(random.choice(string.ascii_lowercase) for i in range(32))) ),
     2525                                                            "".join(random.choice(string.ascii_lowercase) for i in range(32))) ),
    25252526                  tdTestResult(fRc = True) ],
    25262527                [ tdTestDirCreate(sUser = sUser, sPassword = sPassword,
    25272528                                  sDirectory = os.path.join(sScratch,
    2528                                   "".join(random.choice(string.ascii_lowercase) for i in range(128))) ),
     2529                                                            "".join(random.choice(string.ascii_lowercase) for i in range(128))) ),
    25292530                  tdTestResult(fRc = True) ],
    25302531                # Following two should fail on Windows (paths too long). Both should timeout.
    25312532                [ tdTestDirCreate(sUser = sUser, sPassword = sPassword,
    25322533                                  sDirectory = os.path.join(sScratch,
    2533                                   "".join(random.choice(string.ascii_lowercase) for i in range(255))) ),
     2534                                                            "".join(random.choice(string.ascii_lowercase) for i in range(255))) ),
    25342535                  tdTestResult(fRc = False) ],
    25352536                [ tdTestDirCreate(sUser = sUser, sPassword = sPassword,
    25362537                                  sDirectory = os.path.join(sScratch,
    2537                                   "".join(random.choice(string.ascii_lowercase) for i in range(1024))) ),
     2538                                                            "".join(random.choice(string.ascii_lowercase) for i in range(1024)))
     2539                                 ),
    25382540                  tdTestResult(fRc = False) ]
    25392541            ]);
     
    28132815            aaTests.extend([
    28142816                # Invalid stuff.
    2815                 [ tdTestFileRemove(sUser = sUser, sPassword = sPassword, sFile = ''),               tdTestResult(fRc = False) ],
    2816                 [ tdTestFileRemove(sUser = sUser, sPassword = sPassword, sFile = 'C:\\Windows'),    tdTestResult(fRc = False) ],
    2817                 [ tdTestFileRemove(sUser = sUser, sPassword = sPassword, sFile = 'C:\\Windows'),    tdTestResult(fRc = False) ],
     2817                [ tdTestFileRemove(sUser = sUser, sPassword = sPassword, sFile = ''),
     2818                  tdTestResult(fRc = False) ],
     2819                [ tdTestFileRemove(sUser = sUser, sPassword = sPassword, sFile = 'C:\\Windows'),
     2820                  tdTestResult(fRc = False) ],
     2821                [ tdTestFileRemove(sUser = sUser, sPassword = sPassword, sFile = 'C:\\Windows'),
     2822                  tdTestResult(fRc = False) ],
    28182823                # More unusual stuff.
    2819                 [ tdTestFileRemove(sUser = sUser, sPassword = sPassword, sFile = 'z:\\'),           tdTestResult(fRc = False) ],
     2824                [ tdTestFileRemove(sUser = sUser, sPassword = sPassword, sFile = 'z:\\'),
     2825                  tdTestResult(fRc = False) ],
    28202826                [ tdTestFileRemove(sUser = sUser, sPassword = sPassword, sFile = '\\\\uncrulez\\foo'),
    2821                                                                                                    tdTestResult(fRc = False) ],
     2827                  tdTestResult(fRc = False) ],
    28222828                # Non-existing stuff.
    28232829                [ tdTestFileRemove(sUser = sUser, sPassword = sPassword, sFile = 'c:\\Apps\\nonexisting'),
    2824                                                                                                    tdTestResult(fRc = False) ],
     2830                  tdTestResult(fRc = False) ],
    28252831                [ tdTestFileRemove(sUser = sUser, sPassword = sPassword, sFile = 'c:\\Apps\\testFileRemove'),
    2826                                                                                                    tdTestResult(fRc = False) ],
     2832                  tdTestResult(fRc = False) ],
    28272833                # Try to delete system files.
    28282834                [ tdTestFileRemove(sUser = sUser, sPassword = sPassword, sFile = 'c:\\pagefile.sys'),
    2829                                                                                                    tdTestResult(fRc = False) ],
     2835                  tdTestResult(fRc = False) ],
    28302836                [ tdTestFileRemove(sUser = sUser, sPassword = sPassword, sFile = 'c:\\Windows\\kernel32.sys'),
    2831                                                                                                    tdTestResult(fRc = False) ]
     2837                  tdTestResult(fRc = False) ]
    28322838            ]);
    28332839
     
    28362842                    # Try delete some unimportant media stuff.
    28372843                    [ tdTestFileRemove(sUser = sUser, sPassword = sPassword, sFile = 'c:\\Windows\\Media\\chimes.wav'),
    2838                                                                                                    tdTestResult(fRc = True) ],
     2844                      tdTestResult(fRc = True) ],
    28392845                    # Second attempt should fail.
    28402846                    [ tdTestFileRemove(sUser = sUser, sPassword = sPassword, sFile = 'c:\\Windows\\Media\\chimes.wav'),
    2841                                                                                                    tdTestResult(fRc = False) ],
     2847                      tdTestResult(fRc = False) ],
    28422848                    [ tdTestFileRemove(sUser = sUser, sPassword = sPassword, sFile = 'c:\\Windows\\Media\\chord.wav'),
    2843                                                                                                    tdTestResult(fRc = True) ],
     2849                      tdTestResult(fRc = True) ],
    28442850                    [ tdTestFileRemove(sUser = sUser, sPassword = sPassword, sFile = 'c:\\Windows\\Media\\chord.wav'),
    2845                                                                                                    tdTestResult(fRc = False) ]
     2851                      tdTestResult(fRc = False) ]
    28462852                ]);
    28472853        else:
     
    28822888            tdTestSessionEx([ tdStepStatDir('.'),
    28832889                              tdStepStatDir('..'),
    2884                               ]),
     2890                            ]),
    28852891        ];
    28862892        if oTestVm.isWindows():
     
    29052911                                           tdStepStatFile('C:\\Windows\\System32\\kernel32.dll'),
    29062912                                           tdStepStatFile('C:/Windows/System32/kernel32.dll')
    2907                                            ]) ];
     2913                                         ]) ];
    29082914        elif oTestVm.isOS2():
    29092915            aoTests += [ tdTestSessionEx([ tdStepStatDir('C:\\OS2'),
     
    29152921                                           tdStepStatFile('C:\\CONFIG.SYS'),
    29162922                                           tdStepStatFile('C:\\OS2\\DLL\\DOSCALL1.DLL'),
    2917                                            ]) ];
     2923                                         ]) ];
    29182924        else: # generic unix.
    29192925            aoTests += [ tdTestSessionEx([ tdStepStatDir('/'),
     
    29262932                                           tdStepStatFile('/bin/cp'),
    29272933                                           tdStepStatFile('/bin/date'),
    2928                                            ]) ];
     2934                                         ]) ];
    29292935        # None existing stuff.
    29302936        if oTestVm.isWindows() or oTestVm.isOS2():
     
    29392945                                           tdStepStatPathNotFound('N:\\'), # ASSUMES nothing mounted on N:!
    29402946                                           tdStepStatPathNotFound('\\\\NoSuchUncServerName\\NoSuchShare'),
    2941                                            ]) ];
     2947                                         ]) ];
    29422948        else: # generic unix.
    29432949            aoTests += [ tdTestSessionEx([ tdStepStatFileNotFound('/NoSuchFileOrDirectory', ),
     
    29452951                                           tdStepStatPathNotFound('/NoSuchDirectory/'),
    29462952                                           tdStepStatPathNotFound('/NoSuchDirectory/.'),
    2947                                            ]) ];
     2953                                         ]) ];
    29482954        # Invalid parameter check.
    29492955        aoTests += [ tdTestSessionEx([ tdStepStat('', vbox.ComError.E_INVALIDARG), ]), ];
     
    32933299            aaTests.extend([
    32943300                # Destination missing.
    3295                 [ tdTestCopyTo(sUser = sUser, sPassword = sPassword, sSrc = ''),                   tdTestResult(fRc = False) ],
     3301                [ tdTestCopyTo(sUser = sUser, sPassword = sPassword, sSrc = ''),
     3302                  tdTestResult(fRc = False) ],
    32963303                [ tdTestCopyTo(sUser = sUser, sPassword = sPassword, sSrc = 'C:\\Windows',
    3297                                aFlags = [ 1234 ] ),                                                tdTestResult(fRc = False) ],
     3304                               aFlags = [ 1234 ] ),
     3305                  tdTestResult(fRc = False) ],
    32983306                # Source missing.
    3299                 [ tdTestCopyTo(sUser = sUser, sPassword = sPassword, sDst = ''),                   tdTestResult(fRc = False) ],
     3307                [ tdTestCopyTo(sUser = sUser, sPassword = sPassword, sDst = ''),
     3308                  tdTestResult(fRc = False) ],
    33003309                [ tdTestCopyTo(sUser = sUser, sPassword = sPassword, sDst = 'C:\\Windows',
    3301                                aFlags = [ 1234 ] ),                                                tdTestResult(fRc = False) ],
     3310                               aFlags = [ 1234 ] ),
     3311                  tdTestResult(fRc = False) ],
    33023312                # Nothing to copy (source and/or destination is empty).
    3303                 [ tdTestCopyTo(sUser = sUser, sPassword = sPassword, sSrc = 'z:\\'),               tdTestResult(fRc = False) ],
     3313                [ tdTestCopyTo(sUser = sUser, sPassword = sPassword, sSrc = 'z:\\'),
     3314                  tdTestResult(fRc = False) ],
    33043315                [ tdTestCopyTo(sUser = sUser, sPassword = sPassword, sSrc = '\\\\uncrulez\\foo'),
    3305                                                                                                    tdTestResult(fRc = False) ],
     3316
     3317                  tdTestResult(fRc = False) ],
    33063318                [ tdTestCopyTo(sUser = sUser, sPassword = sPassword, sSrc = 'non-exist',
    3307                                sDst = os.path.join(sScratch, 'non-exist.dll')),                    tdTestResult(fRc = False) ],
     3319                               sDst = os.path.join(sScratch, 'non-exist.dll')),
     3320                  tdTestResult(fRc = False) ],
    33083321                # Copying single files.
    33093322                [ tdTestCopyTo(sUser = sUser, sPassword = sPassword, sSrc = sVBoxValidationKitISO,
    3310                                sDst = 'C:\\non-exist\\'),                                          tdTestResult(fRc = False) ],
     3323                               sDst = 'C:\\non-exist\\'),
     3324                  tdTestResult(fRc = False) ],
    33113325                [ tdTestCopyTo(sUser = sUser, sPassword = sPassword, sSrc = sVBoxValidationKitISO,
    3312                                sDst = 'C:\\non\\exist\\'),                                         tdTestResult(fRc = False) ],
     3326                               sDst = 'C:\\non\\exist\\'),
     3327                  tdTestResult(fRc = False) ],
    33133328                [ tdTestCopyTo(sUser = sUser, sPassword = sPassword, sSrc = sVBoxValidationKitISO,
    3314                                sDst = 'C:\\non\\exist\\renamedfile.dll'),                          tdTestResult(fRc = False) ],
     3329                               sDst = 'C:\\non\\exist\\renamedfile.dll'),
     3330                  tdTestResult(fRc = False) ],
    33153331                [ tdTestCopyTo(sUser = sUser, sPassword = sPassword, sSrc = sVBoxValidationKitISO,
    3316                                sDst = os.path.join(sScratch, 'HostGuestAdditions.iso')),           tdTestResult(fRc = True) ],
     3332                               sDst = os.path.join(sScratch, 'HostGuestAdditions.iso')),
     3333                  tdTestResult(fRc = True) ],
    33173334                [ tdTestCopyTo(sUser = sUser, sPassword = sPassword, sSrc = sVBoxValidationKitISO,
    3318                                sDst = os.path.join(sScratch, 'HostGuestAdditions.iso')),           tdTestResult(fRc = True) ],
     3335                               sDst = os.path.join(sScratch, 'HostGuestAdditions.iso')),
     3336                  tdTestResult(fRc = True) ],
    33193337                # Destination is a directory, should fail.
    33203338                [ tdTestCopyTo(sUser = sUser, sPassword = sPassword, sSrc = sVBoxValidationKitISO,
    3321                                sDst = sScratch),                                                   tdTestResult(fRc = False) ]
     3339                               sDst = sScratch),
     3340                  tdTestResult(fRc = False) ]
    33223341                ## @todo Add testing the CopyTo flags here!
    33233342            ]);
     
    33283347                    # Copying directories with contain files we don't have read access to.
    33293348                    [ tdTestCopyTo(sUser = sUser, sPassword = sPassword, sSrc = 'C:\\Windows\\security',
    3330                                    sDst = sScratch),                                               tdTestResult(fRc = False) ],
     3349                                   sDst = sScratch),
     3350                      tdTestResult(fRc = False) ],
    33313351                    # Copying directories with regular files.
    33323352                    [ tdTestCopyTo(sUser = sUser, sPassword = sPassword, sSrc = 'C:\\Windows\\Help',
    3333                                    sDst = sScratch),                                               tdTestResult(fRc = True) ]
     3353                                   sDst = sScratch),
     3354                      tdTestResult(fRc = True) ]
    33343355                ]);
    33353356        else:
     
    33923413                  tdTestResult(fRc = False) ],
    33933414                [ tdTestCopyFrom(sUser = sUser, sPassword = sPassword, sDst = 'C:\\Windows',
    3394                                aFlags = [ 1234 ] ),
     3415                                 aFlags = [ 1234 ] ),
    33953416                  tdTestResult(fRc = False) ],
    33963417                # Nothing to copy (sDst is empty / unreachable).
     
    34013422                  tdTestResult(fRc = False) ],
    34023423                [ tdTestCopyFrom(sUser = sUser, sPassword = sPassword, sSrc = 'non-exist',
    3403                                sDst = os.path.join(sScratch, 'non-exist.dll')),
     3424                                 sDst = os.path.join(sScratch, 'non-exist.dll')),
    34043425                  tdTestResult(fRc = False) ]
    34053426                ## @todo Add testing the CopyFrom aFlags here!
     
    34223443                    # Destination is a directory, should fail.
    34233444                    [ tdTestCopyFrom(sUser = sUser, sPassword = sPassword, sSrc = 'C:\\Windows\\system32\\ole32.dll',
    3424                                    sDst = sScratch),                                                 tdTestResult(fRc = False) ],
     3445                                     sDst = sScratch),
     3446                      tdTestResult(fRc = False) ],
    34253447                    # Copying directories.
    34263448                    [ tdTestCopyFrom(sUser = sUser, sPassword = sPassword, sSrc = 'C:\\Windows\\Web',
    3427                                    sDst = sScratch),                                                 tdTestResult(fRc = True) ]
     3449                                     sDst = sScratch),
     3450                      tdTestResult(fRc = True) ]
    34283451                    ## @todo Add testing the CopyFrom aFlags here!
    34293452                ]);
  • trunk/src/VBox/ValidationKit/tests/network/tdNetBenchmark1.py

    r56295 r57289  
    424424        if fRc and 'tcp-latency' in self.asTests and sAddr is not None:
    425425            for cbPkt in self.acbLatencyPkts:
    426                 fRc = self.txsRunTest(oTxsSession, '%u bytes' % (cbPkt), self.cSecsRun * 1000 * 4, \
    427                     '${CDROM}/${OS/ARCH}/NetPerf${EXESUFF}',
    428                         ('NetPerf', '--client', sAddr, '--interval', self.cSecsRun, '--len', cbPkt, '--mode', 'latency'));
     426                fRc = self.txsRunTest(oTxsSession, '%u bytes' % (cbPkt), self.cSecsRun * 1000 * 4,
     427                                      '${CDROM}/${OS/ARCH}/NetPerf${EXESUFF}',
     428                                      ('NetPerf', '--client', sAddr, '--interval', self.cSecsRun, '--len', cbPkt,
     429                                       '--mode', 'latency'));
    429430                if not fRc:
    430431                    break;
     
    436437        if fRc and 'tcp-throughput' in self.asTests and sAddr is not None:
    437438            for cbPkt in self.acbThroughputPkts:
    438                 fRc = self.txsRunTest(oTxsSession, '%u bytes' % (cbPkt), self.cSecsRun * 2 * 1000 * 4, \
    439                     '${CDROM}/${OS/ARCH}/NetPerf${EXESUFF}',
    440                         ('NetPerf', '--client', sAddr, '--interval', self.cSecsRun, '--len', cbPkt, '--mode', 'throughput'));
     439                fRc = self.txsRunTest(oTxsSession, '%u bytes' % (cbPkt), self.cSecsRun * 2 * 1000 * 4,
     440                                      '${CDROM}/${OS/ARCH}/NetPerf${EXESUFF}',
     441                                      ('NetPerf', '--client', sAddr, '--interval', self.cSecsRun, '--len', cbPkt,
     442                                       '--mode', 'throughput'));
    441443                if not fRc:
    442444                    break;
     
    587589            # Start the test servers on it.
    588590            fRc = self.oGuestToGuestTxs.syncExec('${CDROM}/${OS/ARCH}/NetPerf${EXESUFF}',
    589                     ('NetPerf', '--server', '--daemonize'), fWithTestPipe=False);
     591                                                 ('NetPerf', '--server', '--daemonize'), fWithTestPipe=False);
    590592
    591593        # Loop thru the test VMs.
  • trunk/src/VBox/ValidationKit/tests/storage/tdStorageBenchmark1.py

    r55084 r57289  
    409409        # Prepare test disk, just create filesystem without partition
    410410        reporter.testStart('mkfs.ext4');
    411         fRc = self.txsRunTest(oTxsSession, 'Create FS', 60000, \
    412             '/sbin/mkfs.ext4',
    413                 ('mkfs.ext4', '-F', '/dev/vboxtest'));
     411        fRc = self.txsRunTest(oTxsSession, 'Create FS', 60000,
     412                              '/sbin/mkfs.ext4',
     413                              ('mkfs.ext4', '-F', '/dev/vboxtest'));
    414414        reporter.testDone();
    415415
    416416        reporter.testStart('mount');
    417         fRc = self.txsRunTest(oTxsSession, 'Mount FS', 30000, \
    418             '/bin/mount',
    419                 ('mount', '/dev/vboxtest', '/mnt'));
     417        fRc = self.txsRunTest(oTxsSession, 'Mount FS', 30000,
     418                              '/bin/mount',
     419                              ('mount', '/dev/vboxtest', '/mnt'));
    420420        reporter.testDone();
    421421
     
    423423        if fRc and 'iozone' in self.asTests:
    424424            oStdOut = IozoneStdOutWrapper();
    425             fRc = self.txsRunTestRedirectStd(oTxsSession, '2G', 3600000, \
    426                 '/usr/bin/iozone',
    427                     ('iozone', '-r', '64k', '-s', '2g', '-t', '1', '-T', '-I', '-H', '32','-F', '/mnt/iozone'), \
    428                 (), '', '/dev/null', oStdOut, '/dev/null', '/dev/null');
     425            fRc = self.txsRunTestRedirectStd(oTxsSession, '2G', 3600000,
     426                                             '/usr/bin/iozone',
     427                                             ('iozone', '-r', '64k', '-s', '2g', '-t', '1', '-T', '-I',
     428                                              '-H', '32','-F', '/mnt/iozone'),
     429                                             (), '', '/dev/null', oStdOut, '/dev/null', '/dev/null');
    429430            if fRc is True:
    430431                reporter.log("Initial writer: " + str(oStdOut.getInitWriter()));
     
    447448            oFioWrapper = FioWrapper('64k', '2g', '32', '/mnt');
    448449            fRc = self.txsUploadString(oSession, oTxsSession, oFioWrapper.getConfig(), '${SCRATCH}/aio-test');
    449             fRc = fRc and self.txsRunTestRedirectStd(oTxsSession, '2G', 3600000, \
    450                 '/usr/bin/fio', ('fio', '${SCRATCH}/aio-test'), \
    451                 (), '', '/dev/null', oFioWrapper, '/dev/null', '/dev/null');
     450            fRc = fRc and self.txsRunTestRedirectStd(oTxsSession, '2G', 3600000,
     451                                                     '/usr/bin/fio', ('fio', '${SCRATCH}/aio-test'),
     452                                                     (), '', '/dev/null', oFioWrapper, '/dev/null', '/dev/null');
    452453        else:
    453454            reporter.testDone(fSkipped = True);
  • trunk/src/VBox/ValidationKit/tests/storage/tdStorageStress1.py

    r55084 r57289  
    209209        # Some stupid trickery to guess the location of the iso. ## fixme - testsuite unzip ++
    210210        sVBoxValidationKit_iso = os.path.abspath(os.path.join(os.path.dirname(__file__),
    211                                                  '../../VBoxValidationKitStorIo.iso'));
     211                                                              '../../VBoxValidationKitStorIo.iso'));
    212212        if not os.path.isfile(sVBoxValidationKit_iso):
    213213            sVBoxValidationKit_iso = os.path.abspath(os.path.join(os.path.dirname(__file__),
    214                                                      '../../VBoxValidationKitStorIo.iso'));
     214                                                                  '../../VBoxValidationKitStorIo.iso'));
    215215        if not os.path.isfile(sVBoxValidationKit_iso):
    216216            sVBoxValidationKit_iso = '/mnt/ramdisk/vbox/svn/trunk/validationkit/VBoxValidationKitStorIo.iso';
     
    314314        reporter.testStart('xfstests');
    315315        if fRc and 'xfstests' in self.asTests:
    316             fRc = self.txsRunTest(oTxsSession, 'xfstests', 3600000, \
    317                 '/bin/sh',
    318                     ('sh', '-c', '(cd /tmp/xfstests && ./check -g auto)'), \
    319                     ('TEST_DIR=/mnt/test', 'TEST_DEV=/dev/sdb', 'SCRATCH_MNT=/mnt/scratch', 'SCRATCH_DEV=/dev/sdc', \
    320                      'FSTYP=' + sGuestFs));
     316            fRc = self.txsRunTest(oTxsSession, 'xfstests', 3600000,
     317                                  '/bin/sh',
     318                                  ('sh', '-c', '(cd /tmp/xfstests && ./check -g auto)'),
     319                                  ('TEST_DIR=/mnt/test', 'TEST_DEV=/dev/sdb', 'SCRATCH_MNT=/mnt/scratch', 'SCRATCH_DEV=/dev/sdc',
     320                                   'FSTYP=' + sGuestFs));
    321321            reporter.testDone();
    322322        else:
  • trunk/src/VBox/ValidationKit/tests/unittests/tdUnitTest1.py

    r56771 r57289  
    171171        'testcase/tstCryptoPkcs7Sign': '',# failed: 29330:error:02001002:lib(2):func(1):reason(2):NA:0:fopen('server.pem': '','r')
    172172        'testcase/tstCompressionBenchmark': '', # failed: error: RTZipBlockCompress failed
    173                                         # for 'RTZipBlock/LZJB' (#4): VERR_NOT_SUPPORTED
     173                                                # for 'RTZipBlock/LZJB' (#4): VERR_NOT_SUPPORTED
    174174        'testcase/tstLdr-4': '',            # failed: Failed to get bits for '/home/vbox/test/tmp/bin/testcase/tstLdrObjR0.r0'/0,
    175                                         # rc=VERR_SYMBOL_VALUE_TOO_BIG. aborting test
     175                                            # rc=VERR_SYMBOL_VALUE_TOO_BIG. aborting test
    176176        'tstPDMAsyncCompletionStress': '',  # VERR_INVALID_PARAMETER (cbSize = 0)
    177177        'tstMicro': '',                     # doesn't work on solaris, fix later if we care.
     
    622622            except:
    623623                if sName in [ 'tstAsmStructsRC',    # 32-bit, may fail to start on 64-bit linux. Just ignore.
    624                               ]:
     624                            ]:
    625625                    reporter.logXcpt();
    626626                    fSkipped = True;
Note: See TracChangeset for help on using the changeset viewer.

© 2025 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette