v219_family_test_helpers.h

tests/model/v219_family_test_helpers.h

@file v219_family_test_helpers.h @brief Helpers for v2.1.9 family model tests (gh#44/#45/#46/#47).

Owners: @tvanfossen

testCaseStarting

void V219FamilyListener< Key >::testCaseStarting(Catch::TestCaseInfo const &) override

Clear prompt/KV caches before each scenario for isolation.

tests/model/v219_family_test_helpers.h:316

Result: absent

Verifies

requirementlinkedpath to the implementer
REQ-INFER-020inferredtestCaseStarting → clear_all_prompt_caches
Source · 5 lines
    void testCaseStarting(Catch::TestCaseInfo const& /*tc*/) override {
        if (g_ctx.orchestrator) {
            g_ctx.orchestrator->clear_all_prompt_caches();
        }
    }
Activity · 2 steps
lines 317–317◇ if (g_ctx.orchestrator)lines 318–318g_ctx.orchestrator->clear_all_prompt_caches();

testRunEnded

void V219FamilyListener< Key >::testRunEnded(Catch::TestRunStats const &) override

Shutdown orchestrator at end of run if it loaded.

tests/model/v219_family_test_helpers.h:327

Show on the map →

Called by none

Calls shutdown

Result: absent

Verifies

requirementlinkedpath to the implementer
REQ-INFER-002inferredtestRunEnded → shutdown
REQ-INFER-020inferredtestRunEnded → shutdown
Source · 5 lines
    void testRunEnded(Catch::TestRunStats const& /*stats*/) override {
        if (g_ctx.orchestrator) {
            g_ctx.orchestrator->shutdown();
        }
    }
Activity · 2 steps
lines 328–328◇ if (g_ctx.orchestrator)lines 329–329g_ctx.orchestrator->shutdown();

testRunStarting

void V219FamilyListener< Key >::testRunStarting(Catch::TestRunInfo const &) override

Load registry + config, override tier to Key, init orchestrator.

tests/model/v219_family_test_helpers.h:289

Show on the map →

Called by none

Calls init_orchestrator_for_v219_family, load_harness_inputs

Result: absent

Verifies

requirementlinkedpath to the implementer
REQ-API-004inferredtestRunStarting → init_orchestrator_for_v219_family → init_orchestrator
REQ-API-013inferredtestRunStarting → init_orchestrator_for_v219_family → init_orchestrator
REQ-CFG-001inferredtestRunStarting → load_harness_inputs → load_test_config → load_config
REQ-CFG-002inferredtestRunStarting → load_harness_inputs → load_test_config → load_config → load_config_layers → parse_config_file → parse_top_sections → parse_models_config
REQ-CFG-003inferredtestRunStarting → init_orchestrator_for_v219_family → resolve
REQ-CFG-005inferredtestRunStarting → load_harness_inputs → load_test_config → load_config → load_config_layers → parse_config_file → parse_top_sections → parse_models_config → parse_model_config
REQ-CFG-006inferredtestRunStarting → load_harness_inputs → load_test_config → load_config
REQ-CFG-007inferredtestRunStarting → load_harness_inputs → load_test_config → load_config
REQ-CFG-008inferredtestRunStarting → load_harness_inputs → load_test_config → load_config → load_config_layers → load_bundled_default → resolve_data_dir
REQ-DELEG-005inferredtestRunStarting → load_harness_inputs → load_test_config → load_config → load_config_layers → parse_config_file → parse_top_sections → parse_optional_sections → parse_delegation_config
REQ-INFER-002inferredtestRunStarting → init_orchestrator_for_v219_family → init_orchestrator → initialize → activate_router → ensure_loaded → load_and_activate
REQ-INFER-007inferredtestRunStarting → init_orchestrator_for_v219_family → init_orchestrator → load_grammars_from → load_bundled
REQ-INFER-012inferredtestRunStarting → init_orchestrator_for_v219_family → init_orchestrator → initialize → create_tier_backends → create_adapter
REQ-INFER-019inferredtestRunStarting → init_orchestrator_for_v219_family → large_model_tests_waived
REQ-INFER-020inferredtestRunStarting → init_orchestrator_for_v219_family → init_orchestrator → initialize → build_routing_tables
REQ-INFER-023inferredtestRunStarting → init_orchestrator_for_v219_family → init_orchestrator → initialize → activate_default_tier → get_model → activate_and_track → preload_adapters_for_model
REQ-INFER-027inferredtestRunStarting → load_harness_inputs → load_test_config → load_config → validate_config → validate
REQ-MCP-021inferredtestRunStarting → load_harness_inputs → load_test_config → load_config → load_config_layers → parse_config_file → parse_top_sections → parse_optional_sections → parse_optional_subsections → parse_mcp_config → parse_absolute_path_list
REQ-MCP-023inferredtestRunStarting → load_harness_inputs → load_test_config → load_config → load_config_layers → parse_config_file → parse_top_sections → parse_optional_sections → parse_optional_subsections → parse_mcp_config → parse_mcp_sections → parse_bash_config
REQ-TYPE-005inferredtestRunStarting → load_harness_inputs → load_test_config → load_config → load_config_layers → parse_config_file
Source · 13 lines
    void testRunStarting(Catch::TestRunInfo const& /*info*/) override {
        spdlog::info("Loading v2.1.9 family model: key={}", Key);
        fs::create_directories(LOG_DIR);
        // gh#149: load_harness_inputs records WHICH setup step failed, so a
        // bad bundled_models.yaml is not reported as a missing download.
        bool ok = load_harness_inputs(g_ctx, Key);
        ok = ok && init_orchestrator_for_v219_family(g_ctx, Key);
        if (!ok) {
            spdlog::warn("v2.1.9 family setup did not complete for '{}' — "
                         "test SCENARIOs will SKIP: {}", Key,
                         g_ctx.skip_reason);
        }
    }
Activity · 6 steps
lines 290–290spdlog::info("Loading v2.1.9 family model: key={}", Key);lines 291–291fs::create_directories(LOG_DIR);lines 294–294bool ok = load_harness_inputs(g_ctx, Key);lines 295–295ok = ok && init_orchestrator_for_v219_family(g_ctx, Key);lines 296–296◇ if (!ok)lines 297–299spdlog::warn("v2.1.9 family setup did not complete for '{}' — " "test SCENARIOs will SKIP: {}", Key, g_ctx.skip_reason);