equal
deleted
inserted
replaced
1014 self.abort = [False] |
1014 self.abort = [False] |
1015 self._createdfiles = [] |
1015 self._createdfiles = [] |
1016 |
1016 |
1017 def run(self, args): |
1017 def run(self, args): |
1018 """Run the test suite.""" |
1018 """Run the test suite.""" |
|
1019 self._checktools() |
1019 tests = self.findtests(args) |
1020 tests = self.findtests(args) |
1020 return self._run(tests) |
1021 return self._run(tests) |
1021 |
1022 |
1022 def _run(self, tests): |
1023 def _run(self, tests): |
1023 if self.options.random: |
1024 if self.options.random: |
1438 name = os.path.join(p, program) |
1439 name = os.path.join(p, program) |
1439 if os.name == 'nt' or os.access(name, os.X_OK): |
1440 if os.name == 'nt' or os.access(name, os.X_OK): |
1440 return name |
1441 return name |
1441 return None |
1442 return None |
1442 |
1443 |
1443 def checktools(self): |
1444 def _checktools(self): |
1444 # Before we go any further, check for pre-requisite tools |
1445 # Before we go any further, check for pre-requisite tools |
1445 # stuff from coreutils (cat, rm, etc) are not tested |
1446 # stuff from coreutils (cat, rm, etc) are not tested |
1446 for p in self.REQUIREDTOOLS: |
1447 for p in self.REQUIREDTOOLS: |
1447 if os.name == 'nt' and not p.endswith('.exe'): |
1448 if os.name == 'nt' and not p.endswith('.exe'): |
1448 p += '.exe' |
1449 p += '.exe' |
1458 parser = parser or getparser() |
1459 parser = parser or getparser() |
1459 (options, args) = parseargs(args, parser) |
1460 (options, args) = parseargs(args, parser) |
1460 runner.options = options |
1461 runner.options = options |
1461 os.umask(022) |
1462 os.umask(022) |
1462 |
1463 |
1463 runner.checktools() |
|
1464 |
|
1465 return runner.run(args) |
1464 return runner.run(args) |
1466 |
1465 |
1467 if __name__ == '__main__': |
1466 if __name__ == '__main__': |
1468 sys.exit(main(sys.argv[1:])) |
1467 sys.exit(main(sys.argv[1:])) |