gh#144: the turn queue serialises callers in FIFO order¶
Tests › tests/unit/mcp/external_bridge_test.cpp
What this test is for
Why it exists
The test says nothing about why.
tests/unit/mcp/external_bridge_test.cpp:1035 · its file's page
What it checks (14)
CHECK_FALSE(bridge.turn_in_flight())observesturn_in_flightCHECK(bridge.turn_queue_depth() == 0)observesturn_queue_depthREQUIRE(bridge.begin_turn_wait(5000, &waited))observesbegin_turn_waitCHECK(bridge.turn_in_flight())observesturn_in_flightCHECK(bridge.turn_queue_depth() == 0)observesturn_queue_depthCHECK(waited < 1000)not attributedCHECK_FALSE(bridge.turn_in_flight())observesturn_in_flightREQUIRE(bridge.begin_turn_wait(5000, &waited))observesbegin_turn_waitCHECK(bridge.turn_queue_depth() == 3)observesturn_queue_depthCHECK(bridge.turn_in_flight())observesturn_in_flightREQUIRE(admitted.size() == 3)not attributedCHECK(admitted == std::vector<int>{1, 2, 3})not attributedCHECK(bridge.turn_queue_depth() == 0)observesturn_queue_depthCHECK_FALSE(bridge.turn_in_flight())observesturn_in_flight
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#144: the turn queue serialises callers in FIFO order→turn_in_flight→turn_queue_depth→WHEN→REQUIRE→begin_turn_wait→end_turn_waitWhat 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 2 requirements
Its run touches their code; that is reach, not proof.
- REQ-API-012 inferred
- REQ-BRIDGE-001 inferred