*Not documented*
def repr_traceback(self, item, excinfo, traceback, style):
origin: test.rest.RestReporter
where:
function source:
def repr_traceback(self, item, excinfo, traceback, style):
root = self.get_rootpath(item)
if style == 'long':
for entry in traceback:
link = self.get_linkwriter().get_link(root,
py.path.local(entry.path))
if link:
self.add_rest(Title(Link(entry.path, link),
'line %d' % (entry.lineno,),
belowchar='+', abovechar='+'))
else:
self.add_rest(Title('%s line %d' % (entry.path,
entry.lineno,),
belowchar='+', abovechar='+'))
self.add_rest(LiteralBlock(self.prepare_source(entry.relline,
entry.source)))
elif style == 'short':
text = []
for entry in traceback:
text.append('%s line %d' % (entry.path, entry.lineno))
text.append(' %s' % (entry.source.strip(),))
self.add_rest(LiteralBlock('\n'.join(text)))
self.add_rest(Title(excinfo.typename, belowchar='+'))
self.add_rest(LiteralBlock(excinfo.value))
called in /home/johnny/projects/merlinux/py/dist/py/test/rsession/rest.py
traceback test.rest.RestReporter.repr_traceback.0
called in /home/johnny/projects/merlinux/py/dist/py/test/rsession/rest.py
traceback test.rest.RestReporter.repr_traceback.1
called in /home/johnny/projects/merlinux/py/dist/py/test/rsession/rest.py