[pypy-svn] r10759 - pypy/dist/lib-python-2.3.4/test
hpk at codespeak.net
hpk at codespeak.net
Sun Apr 17 11:59:41 CEST 2005
Author: hpk
Date: Sun Apr 17 11:59:40 2005
New Revision: 10759
Modified:
pypy/dist/lib-python-2.3.4/test/conftest.py
Log:
- sort tests when running from plain directory
- fix initialization of Modules
Modified: pypy/dist/lib-python-2.3.4/test/conftest.py
==============================================================================
--- pypy/dist/lib-python-2.3.4/test/conftest.py (original)
+++ pypy/dist/lib-python-2.3.4/test/conftest.py Sun Apr 17 11:59:40 2005
@@ -29,6 +29,7 @@
w_globals = mod.w_dict
w_filename = space.wrap(str(filepath))
w_execfile = space.builtin.get('execfile')
+ print "calling execfile", w_filename
space.call_function(w_execfile, w_filename, w_globals, w_globals)
w_mod = space.wrap(mod)
w_modules = space.sys.get('modules')
@@ -46,7 +47,9 @@
class RegrDirectory(py.test.collect.Directory):
def run(self):
l = []
- for (name, (enabled, typ)) in testmap.items():
+ items = testmap.items()
+ items.sort()
+ for (name, (enabled, typ)) in items:
if enabled:
l.append(name)
return l
@@ -55,7 +58,7 @@
if name not in testmap:
raise NameError(name)
enabled, typ = testmap[name]
- return typ(name, parent=self)
+ return typ(mydir.join(name), parent=self)
Directory = RegrDirectory
@@ -154,7 +157,7 @@
class UTModuleMainTest(OpErrorModule):
def _prepare(self):
- if hasattr(self, 'space'):
+ if hasattr(self, '_testcases'):
return
self.space = space = getmyspace()
def f():
More information about the Pypy-commit
mailing list