MCPcopy Create free account
hub / github.com/VectifyAI/OpenKB / test_save_load_roundtrip

Function test_save_load_roundtrip

tests/test_config.py:41–50  ·  view source on GitHub ↗
(tmp_path)

Source from the content-addressed store, hash-verified

39
40
41def test_save_load_roundtrip(tmp_path):
42 config_path = tmp_path / "config.yaml"
43 custom = {"model": "gpt-3.5-turbo", "language": "fr"}
44 save_config(config_path, custom)
45 loaded = load_config(config_path)
46 # Custom values override defaults
47 assert loaded["model"] == "gpt-3.5-turbo"
48 assert loaded["language"] == "fr"
49 # Defaults fill in missing keys
50 assert loaded["pageindex_threshold"] == DEFAULT_CONFIG["pageindex_threshold"]
51
52
53def test_load_overrides_defaults(tmp_path):

Callers

nothing calls this directly

Calls 2

save_configFunction · 0.90
load_configFunction · 0.90

Tested by

no test coverage detected