mirror of
https://github.com/moltbot/moltbot.git
synced 2026-05-13 15:47:28 +00:00
test: dedupe auto reply helper mock read
This commit is contained in:
@@ -354,7 +354,8 @@ export async function expectInlineCommandHandledAndStripped(params: {
|
||||
expect(blockReplies.length).toBe(1);
|
||||
expect(blockReplies[0]?.text).toContain(params.blockReplyContains);
|
||||
expect(runEmbeddedPiAgentMock).toHaveBeenCalled();
|
||||
const prompt = runEmbeddedPiAgentMock.mock.calls.at(-1)?.[0]?.prompt ?? "";
|
||||
const lastCall = runEmbeddedPiAgentMock.mock.calls[runEmbeddedPiAgentMock.mock.calls.length - 1];
|
||||
const prompt = lastCall?.[0]?.prompt ?? "";
|
||||
expect(prompt).not.toContain(params.stripToken);
|
||||
expect(text).toBe("ok");
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user