Commits

holger krekel committed ef3c80e

substitute a non-portable conftest hack that pretended that lib_pypy's contents were also in pypy/module

  • Participants
  • Parent commits cc8117b
  • Branches pytest2

Comments (0)

Files changed (2)

lib_pypy/conftest.py

+
+from pypy.conftest import *

pypy/module/conftest.py

-import py
-from pypy.tool.lib_pypy import LIB_PYPY
-
-class MultipleDirCollector(py.test.collect.Collector):
-    def __init__(self, name, mainfspath, fspaths, parent=None, config=None):
-        super(MultipleDirCollector, self).__init__(name, parent, config)
-        self.main_collector = py.test.collect.Directory(mainfspath, self)
-        self.collectors = [py.test.collect.Directory(fspath, self)
-                           for fspath in fspaths]
-
-    def collect(self):
-        return self.main_collector.collect() + self.collectors
-
-
-def pytest_collect_directory(path, parent):
-    if path.basename == 'test_lib_pypy':
-        # collect all the test in BOTH test_lib_pypy and ../../lib_pypy
-        return MultipleDirCollector(path.basename, path, [LIB_PYPY], parent)