Relative path to invocationdir instead rootdir.
This commit is contained in:
parent
80e5098408
commit
402ee6fb9d
|
@ -0,0 +1 @@
|
|||
The path of file skipped by ``@pytest.mark.skip`` in the SKIPPED report is now relative to invocation directory. Previously it was relative to root directory.
|
|
@ -169,6 +169,7 @@ def pytest_runtest_makereport(item, call):
|
|||
# the location of where the skip exception was raised within pytest
|
||||
_, _, reason = rep.longrepr
|
||||
filename, line = item.location[:2]
|
||||
filename = item.config.rootdir.join(filename)
|
||||
rep.longrepr = filename, line + 1, reason
|
||||
|
||||
|
||||
|
|
Loading…
Reference in New Issue