diff options
Diffstat (limited to 'unittest_suite.py')
-rw-r--r-- | unittest_suite.py | 24 |
1 files changed, 12 insertions, 12 deletions
diff --git a/unittest_suite.py b/unittest_suite.py index 4aab623c..b8949b46 100644 --- a/unittest_suite.py +++ b/unittest_suite.py @@ -11,18 +11,18 @@ setup_modules.setup(base_path=root, root_module_name="autotest_lib") suites = [] def lister(dummy, dirname, files): - loader = unittest.TestLoader() - for f in files: - if f.endswith('_unittest.py'): - temp = os.path.join(dirname, f).strip('.py') - mod = ('autotest_lib' - + temp[len(root):].replace('/', '.')) - suite = loader.loadTestsFromName(mod) - suites.append(suite) + loader = unittest.TestLoader() + for f in files: + if f.endswith('_unittest.py'): + temp = os.path.join(dirname, f).strip('.py') + mod = ('autotest_lib' + + temp[len(root):].replace('/', '.')) + suite = loader.loadTestsFromName(mod) + suites.append(suite) if __name__ == "__main__": - os.path.walk(root, lister, None) - alltests = unittest.TestSuite(suites) - runner = unittest.TextTestRunner(verbosity=2) - runner.run(alltests) + os.path.walk(root, lister, None) + alltests = unittest.TestSuite(suites) + runner = unittest.TextTestRunner(verbosity=2) + runner.run(alltests) |