From: Robert Bradshaw Date: Wed, 16 Jul 2008 03:54:22 +0000 (-0700) Subject: Python 2.3 fixes X-Git-Tag: 0.9.8.1~123^2~6 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=858476d4cef87348b3a5eba133c134458ffb21b8;p=cython.git Python 2.3 fixes --- 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)