source_path: py.path.local directly

Via bc7282576.
This commit is contained in:
Daniel Hahler 2020-01-28 19:02:35 +01:00
parent 1cf9e68dbc
commit 7c87874277
1 changed files with 1 additions and 2 deletions

View File

@ -547,9 +547,8 @@ class FixtureRequest:
if has_params:
frame = inspect.stack()[3]
frameinfo = inspect.getframeinfo(frame[0])
source_path = frameinfo.filename
source_path = py.path.local(frameinfo.filename)
source_lineno = frameinfo.lineno
source_path = py.path.local(source_path)
rel_source_path = source_path.relto(funcitem.config.rootdir)
if rel_source_path:
source_path_str = rel_source_path