Report lineno from doctest

This is to fix pytest-sugar#122 issue.
This commit is contained in:
Nguyễn Hồng Quân 2017-07-24 11:52:24 +07:00
parent 1cf826624e
commit af2c153324
1 changed files with 1 additions and 1 deletions

View File

@ -140,7 +140,7 @@ class DoctestItem(pytest.Item):
return super(DoctestItem, self).repr_failure(excinfo)
def reportinfo(self):
return self.fspath, None, "[doctest] %s" % self.name
return self.fspath, self.dtest.lineno, "[doctest] %s" % self.name
def _get_flag_lookup():