From ab21cd451955ff7ed9419ffdbe3dc34bbb397281 Mon Sep 17 00:00:00 2001 From: Zac Medico Date: Sun, 28 Aug 2011 19:59:01 -0700 Subject: Sort test cases, for predictable order. --- pym/portage/tests/__init__.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/pym/portage/tests/__init__.py b/pym/portage/tests/__init__.py index 6f21d10bd..dcf73bab6 100644 --- a/pym/portage/tests/__init__.py +++ b/pym/portage/tests/__init__.py @@ -42,6 +42,7 @@ def main(): if TEST_FILE in files: testDirs.append(root) + testDirs.sort() for mydir in testDirs: suite.addTests(getTests(os.path.join(basedir, mydir), basedir) ) return TextTestRunner(verbosity=2).run(suite) @@ -86,6 +87,7 @@ def getTests(path, base_path): """ files = os.listdir(path) files = [ f[:-3] for f in files if f.startswith("test") and f.endswith(".py") ] + files.sort() parent_path = path[len(base_path)+1:] parent_module = ".".join(("portage", "tests", parent_path)) parent_module = parent_module.replace('/', '.') -- cgit v1.2.3-1-g7c22