cacheprovider: display cachedir also in non-verbose mode if customized

This commit is contained in:
Daniel Hahler 2018-10-30 22:59:11 +01:00
parent 233c2a23de
commit 1f1d4aaf68
1 changed files with 2 additions and 1 deletions

View File

@ -319,7 +319,8 @@ def cache(request):
def pytest_report_header(config):
if config.option.verbose:
"""Display cachedir with --cache-show and if non-default."""
if config.option.verbose or config.getini("cache_dir") != ".pytest_cache":
cachedir = config.cache._cachedir
# TODO: evaluate generating upward relative paths
# starting with .., ../.. if sensible