Skip to content

test: the guard race table gets direct tests #8

Description

@shitianfang

The hardest-to-write-right code in the engine — first-to-fire racing between cancel,
timeout, and budget; the finish-line rule (cancel beats a clean result at the line); the
bail window; the consecutive-error cap — is covered only indirectly, two layers away,
through whole-loop replays.

The interfaces are already exported: drive them directly with a fake phase stream and a
fake clock, one assertion per race-table row (timer fires mid-step; cancel lands during the
final drain; budget exceeded by exactly one step; error cap at 3 consecutive). No
implementation change.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    ready-for-agentspecified enough for an agent session

    Type

    No type

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions