MCPcopy Create free account
hub / github.com/pytest-dev/pytest / test_cache_reportheader_external_abspath

Function test_cache_reportheader_external_abspath

testing/test_cacheprovider.py:192–209  ·  view source on GitHub ↗
(
    pytester: Pytester, tmp_path_factory: TempPathFactory
)

Source from the content-addressed store, hash-verified

190
191
192def test_cache_reportheader_external_abspath(
193 pytester: Pytester, tmp_path_factory: TempPathFactory
194) -> None:
195 external_cache = tmp_path_factory.mktemp(
196 "test_cache_reportheader_external_abspath_abs"
197 )
198
199 pytester.makepyfile("def test_hello(): pass")
200 pytester.makeini(
201 """
202 [pytest]
203 cache_dir = {abscache}
204 """.format(
205 abscache=external_cache
206 )
207 )
208 result = pytester.runpytest("-v")
209 result.stdout.fnmatch_lines([f"cachedir: {external_cache}"])
210
211
212def test_cache_show(pytester: Pytester) -> None:

Callers

nothing calls this directly

Calls 6

fnmatch_linesMethod · 0.80
mktempMethod · 0.45
makepyfileMethod · 0.45
makeiniMethod · 0.45
formatMethod · 0.45
runpytestMethod · 0.45

Tested by

no test coverage detected