fix and test --fixtures location information
This commit is contained in:
parent
20849a44f5
commit
26ab80c4cd
|
@ -761,7 +761,7 @@ def _showfixtures_main(config, session):
|
||||||
if verbose <= 0 and argname[0] == "_":
|
if verbose <= 0 and argname[0] == "_":
|
||||||
continue
|
continue
|
||||||
if verbose > 0:
|
if verbose > 0:
|
||||||
funcargspec = "%s -- %s" %(argname, loc,)
|
funcargspec = "%s -- %s" %(argname, bestrel,)
|
||||||
else:
|
else:
|
||||||
funcargspec = argname
|
funcargspec = argname
|
||||||
tw.line(funcargspec, green=True)
|
tw.line(funcargspec, green=True)
|
||||||
|
|
|
@ -1590,7 +1590,7 @@ class TestShowFixtures:
|
||||||
def test_show_fixtures_verbose(self, testdir):
|
def test_show_fixtures_verbose(self, testdir):
|
||||||
result = testdir.runpytest("--fixtures", "-v")
|
result = testdir.runpytest("--fixtures", "-v")
|
||||||
result.stdout.fnmatch_lines([
|
result.stdout.fnmatch_lines([
|
||||||
"*tmpdir*",
|
"*tmpdir*--*tmpdir.py*",
|
||||||
"*temporary directory*",
|
"*temporary directory*",
|
||||||
]
|
]
|
||||||
)
|
)
|
||||||
|
|
Loading…
Reference in New Issue