From 858476d4cef87348b3a5eba133c134458ffb21b8 Mon Sep 17 00:00:00 2001 From: Robert Bradshaw Date: Tue, 15 Jul 2008 20:54:22 -0700 Subject: [PATCH] Python 2.3 fixes --- Cython/Compiler/Nodes.py | 2 +- runtests.py | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/Cython/Compiler/Nodes.py b/Cython/Compiler/Nodes.py index d389bd6c..e94101cd 100644 --- a/Cython/Compiler/Nodes.py +++ b/Cython/Compiler/Nodes.py @@ -177,7 +177,7 @@ class Node(object): if isinstance(x, Node): return x.dump(level) elif isinstance(x, list): - return "[%s]" % ", ".join(dump_child(item, level) for item in x) + return "[%s]" % ", ".join([dump_child(item, level) for item in x]) else: return repr(x) diff --git a/runtests.py b/runtests.py index 50713f03..191c437f 100644 --- a/runtests.py +++ b/runtests.py @@ -295,7 +295,7 @@ def collect_unittests(path, suite, selectors): module = __import__(modulename) for x in modulename.split('.')[1:]: module = getattr(module, x) - suite.addTests(loader.loadTestsFromModule(module)) + suite.addTests([loader.loadTestsFromModule(module)]) if __name__ == '__main__': from optparse import OptionParser @@ -369,7 +369,7 @@ if __name__ == '__main__': if options.filetests: filetests = TestBuilder(ROOTDIR, WORKDIR, selectors, options.annotate_source, options.cleanup_workdir) - test_suite.addTests(filetests.build_suite()) + test_suite.addTests([filetests.build_suite()]) unittest.TextTestRunner(verbosity=options.verbosity).run(test_suite) -- 2.26.2