Skip to content

Commit cd51868

Browse files
carderneTrigger.dev RepoOps
authored andcommitted
test(dashboard-agent): fix flaky phase duration comparison
## Summary Stop the duration-format equivalence test from comparing independently generated observation timestamps. All other timeline fields remain covered by the equality assertion. Verified: all 49 tests in tool-curation.test.ts pass. Mono-RevId: c679c63a9555eaf894d86aa6522026ec3584f3a9
1 parent 9272d01 commit cd51868

1 file changed

Lines changed: 5 additions & 1 deletion

File tree

‎internal-packages/dashboard-agent/src/tool-curation.test.ts‎

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -823,7 +823,11 @@ describe("derivePhases", () => {
823823
},
824824
};
825825

826-
expect(derivePhases(agentTrace, run, "agent")).toEqual(derivePhases(trace, run, "legacy"));
826+
const agentTimeline = derivePhases(agentTrace, run, "agent")!;
827+
const legacyTimeline = derivePhases(trace, run, "legacy")!;
828+
829+
// Each call stamps its own observation time, independent of the duration format.
830+
expect(agentTimeline).toEqual({ ...legacyTimeline, asOf: agentTimeline.asOf });
827831
});
828832

829833
it("flags truncation when the phase cap itself dropped spans", () => {

0 commit comments

Comments
 (0)