traceback for test.rest.RestReporter.get_item_name

/home/johnny/projects/merlinux/py/dist/py/test/rsession/rest.py:111

   def skips(self):
       # XXX hrmph, copied code
       texts = {}
       for event in self.skipped_tests_outcome:
           colitem = event.item
           if isinstance(event, report.ReceivedItemOutcome):
               outcome = event.outcome
               text = outcome.skipped
->             itemname = self.get_item_name(event, colitem)
           elif isinstance(event, report.SkippedTryiter):
               text = str(event.excinfo.value)
               itemname = "/".join(colitem.listnames())
           if text not in texts:
               texts[text] = [itemname]
           else:
               texts[text].append(itemname)
       if texts:
           self.add_rest(Title('Reasons for skipped tests:', belowchar='+'))
           for text, items in texts.items():
               for item in items:
                   self.add_rest(ListItem('%s: %s' % (item, text)))

/home/johnny/projects/merlinux/py/dist/py/test/rsession/testing/test_rest.py:135

   def test_skips(self):
       reporter.skips()
       assert stdout.getvalue() == ''
       reporter.skipped_tests_outcome = [
           FakeOutcome(outcome=Container(skipped='problem X'),
                       item=Container(listnames=lambda: ['foo', 'bar.py'])),
           FakeTryiter(excinfo=Container(value='problem Y'),
                       item=Container(listnames=lambda: ['foo', 'baz.py']))]
->     reporter.skips()
       assert stdout.getvalue() == """\
   Reasons for skipped tests\:
   +++++++++++++++++++++++++++
   
   * foo/bar.py\: problem X
   
   * foo/baz.py\: problem Y
   
   """

/home/johnny/projects/merlinux/py/dist/py/test/item.py:79

   def execute(self, target, *args):
       """ default implementation for calling a test target is to
               simply call it.
           """
->     target(*args)

/home/johnny/projects/merlinux/py/dist/py/test/item.py:73

   def run(self):
       self.state.prepare(self) 
->     self.execute(self.obj, *self.args)

/home/johnny/projects/merlinux/py/dist/py/test/rsession/executor.py:22

   def execute(self):
       try:
->         self.item.run()
           outcome = Outcome()
       except py.test.Item.Skipped, e: 
           outcome = Outcome(skipped=str(e))
       except (KeyboardInterrupt, SystemExit):
           raise
       except:
           excinfo = py.code.ExceptionInfo()
           if isinstance(self.item, py.test.Function): 
               fun = self.item.obj # hope this is stable 
               code = py.code.Code(fun)
               excinfo.traceback = excinfo.traceback.cut(
                       path=code.path, firstlineno=code.firstlineno)
           outcome = Outcome(excinfo=excinfo, setupfailure=False)
           if self.usepdb:
               if self.reporter is not None:
                   self.reporter(report.ImmediateFailure(self.item,
                       ReprOutcome(outcome.make_repr())))
               import pdb
               pdb.post_mortem(excinfo._excinfo[2])
               # XXX hmm, we probably will not like to continue from that point
               # or we do?
               raise SystemExit()
       outcome.stdout = ""
       outcome.stderr = ""
       return outcome

/home/johnny/projects/merlinux/py/dist/py/test/rsession/local.py:31

   def plain_runner(item, session, reporter):
       # box executor is doing stdout/err catching for us, let's do it here
       startcapture(session)
       r = RunExecutor(item, usepdb=session.config.option.usepdb, reporter=reporter)
->     outcome = r.execute()
       outcome = ReprOutcome(outcome.make_repr())
       outcome.stdout, outcome.stderr = finishcapture(session)
       return outcome

/home/johnny/projects/merlinux/py/dist/py/test/rsession/local.py:47

   def apigen_runner(item, session, reporter):
       r = RunExecutor(item, reporter=reporter)
       session.tracer.start_tracing()
->     retval = plain_runner(item, session, reporter)
       session.tracer.end_tracing()
       return retval