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

Method simple_module

testing/test_pathlib.py:273–277  ·  view source on GitHub ↗
(self, tmp_path: Path)

Source from the content-addressed store, hash-verified

271
272 @pytest.fixture
273 def simple_module(self, tmp_path: Path) -> Path:
274 fn = tmp_path / "_src/tests/mymod.py"
275 fn.parent.mkdir(parents=True)
276 fn.write_text("def foo(x): return 40 + x")
277 return fn
278
279 def test_importmode_importlib(self, simple_module: Path, tmp_path: Path) -> None:
280 """`importlib` mode does not change sys.path."""

Callers

nothing calls this directly

Calls 1

mkdirMethod · 0.45

Tested by

no test coverage detected