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

Method test_custom_ini

testing/test_findpaths.py:24–28  ·  view source on GitHub ↗

[pytest] section in any .ini file is read correctly

(self, tmp_path: Path)

Source from the content-addressed store, hash-verified

22 assert load_config_dict_from_file(fn) == {"x": "1"}
23
24 def test_custom_ini(self, tmp_path: Path) -> None:
25 """[pytest] section in any .ini file is read correctly"""
26 fn = tmp_path / "custom.ini"
27 fn.write_text("[pytest]\nx=1", encoding="utf-8")
28 assert load_config_dict_from_file(fn) == {"x": "1"}
29
30 def test_custom_ini_without_section(self, tmp_path: Path) -> None:
31 """Custom .ini files without [pytest] section are not considered for configuration"""

Callers

nothing calls this directly

Calls 1

Tested by

no test coverage detected