sorting should be an option collector->child interface

--HG--
branch : trunk
This commit is contained in:
Samuele Pedroni
2009-05-19 18:28:51 +02:00
parent 842d14cd33
commit 3b23b98cb5
5 changed files with 20 additions and 34 deletions

View File

@@ -64,7 +64,17 @@ class FunctionCollector(py.test.collect.Collector):
function = self.parent.Function(name=name, parent=self,
callspec=callspec, callobj=self.obj)
l.append(function)
return l
return l
def reportinfo(self):
try:
return self._fslineno, self.name
except AttributeError:
pass
fspath, lineno = py.code.getfslineno(self.obj)
self._fslineno = fspath, lineno
return fspath, lineno, self.name
class FuncargRequest:
_argprefix = "pytest_funcarg__"