Route STEP_DONE through reviewer

This commit is contained in:
ejclaw
2026-04-24 12:03:12 +09:00
parent 6d28a4ae19
commit f84dccfa10
8 changed files with 105 additions and 156 deletions

View File

@@ -83,7 +83,7 @@ describe('message-runtime-follow-up', () => {
expect(enqueue).toHaveBeenCalledTimes(1);
});
it('uses the fallback STEP_DONE verdict to schedule owner follow-ups when the owner keeps the task active', () => {
it('does not use fallback owner STEP_DONE verdict to schedule owner follow-ups while active', () => {
const enqueue = vi.fn();
const result = dispatchPairedFollowUpForEvent({
chatJid: 'group@test',
@@ -102,14 +102,12 @@ describe('message-runtime-follow-up', () => {
});
expect(result).toMatchObject({
kind: 'paired-follow-up',
intentKind: 'owner-follow-up',
scheduled: true,
kind: 'none',
taskStatus: 'active',
lastTurnOutputRole: 'owner',
lastTurnOutputVerdict: 'step_done',
});
expect(enqueue).toHaveBeenCalledTimes(1);
expect(enqueue).not.toHaveBeenCalled();
});
it('prefers the latest persisted turn output over the fallback delivery role when both are present', () => {