Skip to content

Flaky: WorkspaceApiTests.Home_ShouldReturnCurrentUserSummaryOnly — CapturesNeedingTriage off-by-one under full-suite ordering (cross-test contamination) #1418

Description

@Chris0Jeky

Flake evidence

Taskdeck.Api.Tests.WorkspaceApiTests.Home_ShouldReturnCurrentUserSummaryOnly (WorkspaceApiTests.cs:160) failed once during a full-suite gate run on PR #1412's head 7fb32873 (2026-07-17 overnight run):

Expected home.Workload.CapturesNeedingTriage to be 2, but found 3.

Rerun protocol on the IDENTICAL head: 3× isolated class runs (12/0 each) + 1× full-suite rerun (7355/0, Api.Tests 2085/0) — the failure did not reproduce. Classification: order-dependent/flaky, not a deterministic regression. The off-by-one shape (one extra capture needing triage) suggests cross-test data contamination — another test's capture row leaking into this test's per-user Home workload aggregation window, i.e. shared-database test isolation rather than product code.

Not part of the structurally-closed flake families (hosted-worker isolation #1394, Redis seam #1392, AuditRetention #1391) — this is a new, distinct family (workspace/Home summary counts).

Suggested direction

Reproduce by running Api.Tests with the same ordering pressure (full-suite context), then isolate WorkspaceApiTests' data setup: either scope the Home workload assertion to fixtures created by the test (unique user/board markers) or harden the fixture isolation (fresh db per class, or filter assertions on test-owned entity ids) in line with the #1394 worker-isolation factory conventions.

Provenance

Metadata

Metadata

Assignees

No one assigned

    Projects

    Status
    Done

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions