gh#182: a model-supplied max_turns bounds the delegated child

Tests › tests/unit/core/engine_test.cpp

absent Not in the packaged run: no test report names it.

What this test is for

Why it exists

The test says nothing about why.

tests/unit/core/engine_test.cpp:4139 · its file's page

What it checks (12)

  1. CHECK(out.child_iterations == 2) observes delegate_once via out
  2. CHECK(out.carrier.find(gh182::kChildWork) != std::string::npos) observes delegate_once via out
  3. CHECK(out.carrier.find("[iteration cap reached after ") != std::string::npos) observes delegate_once via out
  4. CHECK(out.carrier.rfind("[DELEGATION FAILED: eng]", 0) == 0) observes delegate_once via out
  5. REQUIRE_FALSE(json.empty()) observes delegate_complete_json via json
  6. CHECK(j.at("success").get<bool>() == false) not attributed
  7. CHECK(j.at("target_tier").get<std::string>() == "eng") not attributed
  8. CHECK(j.at("result_kind").get<std::string>() == "delegation_failed") not attributed
  9. CHECK(out.child_iterations == 2) observes delegate_once via out
  10. CHECK(out.child_iterations == 5) observes delegate_once via out
  11. CHECK(out.child_iterations == 4) observes delegate_once via out
  12. CHECK(out.child_iterations == 3) observes delegate_once via out

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

gh#182: a model-supplied max_turns bounds the delegated child→WHEN→delegate_once→delegate_complete_json

What 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.

gh#182: a model-supplied max_turns bounds the delegated child · 12 checksWHENfailure_detailREQ-API-012 · inferreddelegate_once… 3 calls …check_compactionREQ-COMPACT-001 · inferreddelegate_oncerun_loopREQ-COMPACT-002 · inferreddelegate_once… 5 calls …execute_pending_pipelineREQ-DELEG-001 · inferreddelegate_oncerun_looploopresolve_max_iterationsREQ-DELEG-002 · inferreddelegate_once… 6 calls …finalize_delegation_resultREQ-DELEG-003 · inferreddelegate_once… 5 calls …execute_pending_pipelineREQ-DELEG-004 · inferreddelegate_once… 6 calls …resolve_session_rootREQ-DELEG-005 · inferreddelegate_once… 6 calls …resolve_resume_delegationREQ-DELEG-006 · inferreddelegate_onceset_hooksREQ-HOOK-002 · inferreddelegate_onceset_tier_resolutionREQ-IDEN-001 · inferreddelegate_once… 5 calls …try_auto_chainREQ-IDEN-003 · inferred

and 9 more requirement paths, listed below.

Also reaches 21 requirements

Its run touches their code; that is reach, not proof.