Comprehensive config exercises every parse_* helper¶
Tests › tests/unit/config/loader_test.cpp
What this test is for
Why it exists
The test says nothing about why.
tests/unit/config/loader_test.cpp:191 · its file's page
What it checks (103)
REQUIRE(err.empty())observesparse_config_fileviaerrCHECK(config.log_level == "WARN")not attributedCHECK(config.inject_model_context == true)not attributedCHECK(config.vram_reserve_mb == 512)not attributedCHECK(config.ggml_logging == true)not attributedCHECK(config.llama_log_path == "/tmp/llama-custom.log")not attributedCHECK(config.console_logging == false)not attributedREQUIRE(config.constitution.has_value())not attributedREQUIRE(config.app_context.has_value())not attributedCHECK(config.models.default_tier == "lead")not attributedREQUIRE(config.models.router.has_value())not attributedCHECK(config.models.router->adapter == "qwen35")not attributedCHECK(config.models.router->context_length == 8192)not attributedREQUIRE(config.models.tiers.count("lead") == 1)not attributedCHECK(lead.adapter == "qwen35")not attributedCHECK(lead.context_length == 131072)not attributedCHECK(lead.gpu_layers == 40)not attributedCHECK(lead.keep_warm == true)not attributedCHECK(lead.use_mlock == true)not attributedCHECK(lead.reasoning_budget == 2000)not attributedCHECK(lead.cache_type_k == "q8_0")not attributedCHECK(lead.cache_type_v == "q8_0")not attributedCHECK(lead.n_batch == 1024)not attributedCHECK(lead.n_ubatch == 256)not attributedCHECK(lead.n_threads == 8)not attributedCHECK(lead.tensor_split == "0.5,0.5")not attributedCHECK(lead.split_mode == "row")not attributedCHECK(lead.main_gpu == 1)not attributedCHECK(lead.offload_kqv == false)not attributedCHECK(lead.rope_freq_base == 100000.0f)not attributedCHECK(lead.rope_freq_scale == 0.5f)not attributedCHECK(lead.n_parallel == 4)not attributedCHECK(lead.flash_attn == true)not attributedREQUIRE(lead.allowed_tools.has_value())not attributedCHECK(lead.allowed_tools->size() == 2)not attributedCHECK_FALSE(lead.mmproj_path.empty())not attributedCHECK(config.routing.enabled == true)not attributedCHECK(config.routing.fallback_tier == "lead")not attributedREQUIRE(config.routing.classification_prompt.has_value())not attributedCHECK(config.routing.classification_prompt->find( "Pick the right tier") != std::string::npos)not attributedCHECK(config.routing.tier_map.size() == 2)not attributedCHECK(config.routing.tier_map.at("code") == "eng")not attributedCHECK(config.routing.handoff_rules.size() == 2)not attributedCHECK(config.compaction.enabled == true)not attributedCHECK(config.compaction.threshold_percent == Catch::Approx(0.8f))not attributedCHECK(config.compaction.preserve_recent_turns == 5)not attributedCHECK(config.compaction.summary_max_tokens == 512)not attributedCHECK(config.compaction.notify_user == true)not attributedCHECK(config.compaction.save_full_history == true)not attributedCHECK(config.compaction.tool_result_ttl == 10)not attributedCHECK(config.compaction.warning_threshold_percent == Catch::Approx(0.6f))not attributedCHECK(config.permissions.allow.size() == 2)not attributedCHECK(config.permissions.deny.size() == 1)not attributedCHECK(config.permissions.auto_approve == true)not attributedCHECK(config.mcp.enable_entropic == true)not attributedCHECK(config.mcp.enable_filesystem == true)not attributedCHECK(config.mcp.enable_bash == false)not attributedCHECK(config.mcp.enable_git == true)not attributedCHECK(config.mcp.enable_diagnostics == true)not attributedCHECK(config.mcp.enable_web == true)not attributedCHECK(config.mcp.server_timeout_seconds == 30)not attributedCHECK_FALSE(config.mcp.working_dir.empty())not attributedCHECK(config.mcp.filesystem.diagnostics_on_edit == true)not attributedCHECK(config.mcp.filesystem.fail_on_errors == false)not attributedCHECK(config.mcp.filesystem.diagnostics_timeout == 10)not attributedCHECK(config.mcp.filesystem.allow_outside_root == entropic::OutsideRootAccess::allow)not attributedCHECK(config.mcp.filesystem.max_read_context_pct == Catch::Approx(0.5f))not attributedCHECK(config.mcp.filesystem.max_read_bytes == 65536)not attributedCHECK(config.mcp.filesystem.max_walk_entries == 1000)not attributedCHECK(config.mcp.external.enabled == true)not attributedCHECK(config.mcp.external.rate_limit == 100)not attributedREQUIRE(config.mcp.external.socket_path.has_value())not attributedCHECK(config.mcp.external.ask_streaming == false)not attributedCHECK(config.mcp.external.tool_prefix == "sumac")not attributedCHECK(config.mcp.external.server_name == "sumac-reviewer")not attributedREQUIRE(config.mcp.external.tool_descriptions.count("ask") == 1)not attributedCHECK(config.mcp.external.tool_descriptions.at("ask") == "Review this repository against the documentation " "ruleset.")not attributedCHECK(config.mcp.external.tool_descriptions.at("status") == "Reviewer engine health.")not attributedCHECK(config.mcp.external.tool_descriptions.count("nope") == 0)not attributedCHECK(fresh.tool_prefix == "entropic")not attributedCHECK(fresh.server_name == "entropic")not attributedCHECK(fresh.tool_descriptions.empty())not attributedCHECK(config.generation.max_tokens == 2048)not attributedCHECK(config.generation.default_temperature == Catch::Approx(0.5f))not attributedCHECK(config.generation.default_top_p == Catch::Approx(0.85f))not attributedCHECK(config.lsp.enabled == true)not attributedCHECK(config.lsp.python_enabled == true)not attributedCHECK(config.lsp.c_enabled == false)not attributedCHECK(config.prompt_cache.enabled == false)not attributedCHECK(config.prompt_cache.log_hits == false)not attributedCHECK(config.prompt_cache.max_bytes == 268435456)not attributedCHECK(config.inference.speculative.enabled == true)not attributedCHECK(config.inference.speculative.n_draft == 8)not attributedCHECK(config.inference.speculative.draft.context_length == 4096)not attributedCHECK(config.inference.speculative.draft.flash_attn == false)not attributedCHECK(config.constitutional_validation.enabled == true)not attributedCHECK(config.constitutional_validation.max_revisions == 2)not attributedCHECK(config.constitutional_validation.max_critique_tokens == 256)not attributedCHECK(config.constitutional_validation.temperature == Catch::Approx(0.2f))not attributedCHECK(config.constitutional_validation.enable_thinking == false)not attributedCHECK(config.constitutional_validation.priority == 50)not attributedCHECK(config.constitutional_validation.grammar_key == "constitutional")not attributedCHECK(config.constitutional_validation.skip_tiers.size() == 1)not attributed
Where the product reaches it
No product flow reaches this code: no product entry point's flow calls any of the functions this test calls.
Call flow
Comprehensive config exercises every parse_* helper→load_test_registry→WHEN→parse_config_file→test_data→REQUIREWhat it reaches
Each row runs from this test, through the calls it makes, to the code a requirement names. If that code breaks, the test's checks are what should catch it. Reaching is not proving: a check only proves what it observes. No mutation records were given, so these rows say what the test REACHES.
Also reaches 10 requirements
Its run touches their code; that is reach, not proof.
- REQ-API-012 inferred
- REQ-CFG-001 inferred
- REQ-CFG-002 inferred
- REQ-CFG-003 inferred
- REQ-CFG-005 inferred
- REQ-CFG-006 inferred
- REQ-DELEG-005 inferred
- REQ-MCP-021 inferred
- REQ-MCP-023 inferred
- REQ-TYPE-005 inferred