Skip to content

Make stale scheduled-claim restart test deterministic #179

Description

@owainlewis

Problem

The Ubuntu PR run for #178 intermittently failed in jobs::tests::live_scheduled_claim_survives_restart_and_stale_claim_becomes_deliverable at src/jobs.rs:5391. The test expected the recovered row status to be failed, but it was still running. The same commit passed locally, on macOS CI, and on an unchanged Ubuntu retry.

Run: https://github.com/owainlewis/push/actions/runs/30565403853

Outcome

Make the lease-expiry and restart scenario deterministic without weakening the production recovery assertion.

Acceptance criteria

  • The test controls or explicitly advances the relevant lease clock instead of depending on runner timing.
  • It still proves that a live scheduled claim survives restart and that a stale claim becomes deliverable.
  • Focused repeated runs pass on Linux and macOS.
  • The full locked test suite passes.

Checks

  • Run the focused test repeatedly under constrained CI-like timing.
  • Run cargo test --locked.
  • Run formatting and clippy.

Metadata

Metadata

Assignees

No one assigned

    Labels

    agent-readyScoped enough for an agent to pick upbugSomething isn't workingciCI / build infrahardeningRobustness / correctness

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions