MCPcopy
hub / github.com/pytest-dev/pytest / test_config_cache

Method test_config_cache

testing/test_cacheprovider.py:121–137  ·  view source on GitHub ↗
(self, pytester: Pytester)

Source from the content-addressed store, hash-verified

119 )
120
121 def test_config_cache(self, pytester: Pytester) -> None:
122 pytester.makeconftest(
123 """
124 def pytest_configure(config):
125 # see that we get cache information early on
126 assert hasattr(config, "cache")
127 """
128 )
129 pytester.makepyfile(
130 """
131 def test_session(pytestconfig):
132 assert hasattr(pytestconfig, "cache")
133 """
134 )
135 result = pytester.runpytest()
136 assert result.ret == 0
137 result.stdout.fnmatch_lines(["*1 passed*"])
138
139 def test_cachefuncarg(self, pytester: Pytester) -> None:
140 pytester.makepyfile(

Callers

nothing calls this directly

Calls 4

fnmatch_linesMethod · 0.80
makeconftestMethod · 0.45
makepyfileMethod · 0.45
runpytestMethod · 0.45

Tested by

no test coverage detected