Skip to content

Commit 5233847

Browse files
committed
test(server): verify unread shell watermark after compaction
1 parent 8f839a8 commit 5233847

1 file changed

Lines changed: 12 additions & 0 deletions

File tree

‎apps/server/src/orchestration-v2/runtimeLayer.test.ts‎

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5782,6 +5782,18 @@ it.layer(layerSharedApplicationDataPlaneTest)("visited projection", (it) => {
57825782
projection.thread.lastVisitedAt,
57835783
DateTime.subtract(turnCompletedAt, { milliseconds: 1 }),
57845784
);
5785+
const shell = yield* orchestrator.getThreadShell(threadId);
5786+
assert.deepEqual(shell!.latestRunCompletedAt, turnCompletedAt);
5787+
assert.deepEqual(shell!.lastVisitedAt, projection.thread.lastVisitedAt);
5788+
5789+
yield* orchestrator.dispatch({
5790+
type: "thread.visit",
5791+
commandId: CommandId.make(`${threadId}:visit`),
5792+
threadId,
5793+
visitedAt: DateTime.formatIso(turnCompletedAt),
5794+
});
5795+
const revisited = yield* orchestrator.getThreadShell(threadId);
5796+
assert.deepEqual(revisited!.lastVisitedAt, turnCompletedAt);
57855797
}),
57865798
);
57875799
});

0 commit comments

Comments
 (0)