返回 last30days-skill
test_env_include_sources_default.py
根目录 / tests / test_env_include_sources_default.py
1 from lib import env
2
3
4 def test_include_sources_defaults_to_empty_string(monkeypatch, tmp_path):
5 # Ensure the env var is not set
6 monkeypatch.delenv("INCLUDE_SOURCES", raising=False)
7
8 # Avoid reading any real user config file by patching the resolved module path directly
9 monkeypatch.setattr(env, "CONFIG_FILE", tmp_path / "does-not-exist.env")
10
11 cfg = env.get_config()
12
13 assert "INCLUDE_SOURCES" in cfg
14 assert cfg["INCLUDE_SOURCES"] == ""
15
15 lines PYTHON